CLI
dotnet restore --locked-mode
Fails instead of silently updating a lock file when declared dependencies differ.
Formal Syntax & Structure
csharp syntaxcsharp
dotnet restore --locked-modeWorking Example
Example Snippetcsharp
// Documentary fragment; see linked lesson for context.dotnet restore --locked-mode