Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EF Commands #4555

Closed
dneimke opened this issue Feb 13, 2016 · 7 comments
Closed

EF Commands #4555

dneimke opened this issue Feb 13, 2016 · 7 comments

Comments

@dneimke
Copy link

dneimke commented Feb 13, 2016

is it possible to run EF Commands again ? e.g. is there a dotnet CLI version of the EF commands that we can run?

@gdoron
Copy link

gdoron commented Feb 14, 2016

#4406

@bricelam
Copy link
Contributor

They should be usable (but not throughly tested) now. Add the following to your project.json

{
  "tools": {
    "dotnet-ef": "1.0.0-*"
  }
}

Then restore, build, and use the tool just like you did dnx ef

cd src\MyProject
dotnet restore
dotnet build
dotnet ef dbcontext list

@bricelam
Copy link
Contributor

Closing. Use #3925 to track further progress of the .NET-Core-CLI-based commands.

@dneimke
Copy link
Author

dneimke commented Feb 16, 2016

Thanks!

@capesean
Copy link

When I run an EF command, I get No executable found matching command "dotnet-ef"

Am I missing something?

@bricelam
Copy link
Contributor

Did you run dotnet restore first? Are you in the directory containing the project.json?

@capesean
Copy link

Trying it in an "empty" project I now get Failed to initialize CoreCLRm after running dotnet restore successfully.

project.json is:

{
  "compilationOptions": {
    "emitEntryPoint": true
  },
  "dependencies": {
    "Microsoft.AspNetCore.Hosting": "1.0.0-*",
    "Microsoft.EntityFrameworkCore": "1.0.0-*",
    "Microsoft.EntityFrameworkCore.Commands": "1.0.0-*",
    "Microsoft.EntityFrameworkCore.SqlServer": "1.0.0-*",
  },
  "commands": {
      "ef": "EntityFrameworkCore.Commands"
  },
  "frameworks": {
    "net451": { }
  },
  "tools": {
    "dotnet-ef": "1.0.0-*"
  }
}

And:

PM> dotnet --version
.NET Command Line Tools (1.0.0-beta-001496)

Product Information:
 Version:     1.0.0-beta-001496
 Commit Sha:  962411969e

Runtime Environment:
 OS Name:     Windows
 OS Version:  6.1.7601
 OS Platform: Windows
 Runtime Id:  win7-x64

@ajcvickers ajcvickers reopened this Oct 16, 2022
@ajcvickers ajcvickers closed this as not planned Won't fix, can't repro, duplicate, stale Oct 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants