Skip to content

Commit

Permalink
Namespace and ContextNamespace options only available in 5.0 (#2358)
Browse files Browse the repository at this point in the history
State that --namespace and --context-namespace only available in EFCore 5.0.
  • Loading branch information
lajones committed May 5, 2020
1 parent 0d99f3f commit 0b8475c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion entity-framework/core/managing-schemas/scaffolding.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ Scaffold-DbContext ... -ContextDir Data -OutputDir Models
dotnet ef dbcontext scaffold ... --context-dir Data --output-dir Models
```

By default, the namespace will be the root namespace plus the names of any subdirectories under the project's root directory. However you can override the namespace for all output classes by using `-Namespace` (PMC) or `--namespace` (CLI). You can also override the namespace for just the DbContext class using `-ContextNamespace` (PMC) or `--context-namespace` (CLI).
By default, the namespace will be the root namespace plus the names of any subdirectories under the project's root directory. However, from EFCore 5.0 onwards, you can override the namespace for all output classes by using `-Namespace` (PMC) or `--namespace` (CLI). You can also override the namespace for just the DbContext class using `-ContextNamespace` (PMC) or `--context-namespace` (CLI).

``` powershell
Scaffold-DbContext ... -Namespace Your.Namespace -ContextNamespace Your.DbContext.Namespace
Expand Down

0 comments on commit 0b8475c

Please sign in to comment.