Class DotnetPackageAddOptions
- Namespace
- Invex.Atom.Module.Dotnet.Cli
- Assembly
- Invex.Atom.Module.Dotnet.dll
public sealed record DotnetPackageAddOptions
- Inheritance
-
objectDotnetPackageAddOptions
Constructors
DotnetPackageAddOptions()
public DotnetPackageAddOptions()
Properties
File
The file-based app to operate on.
public string? File { get; init; }
Property Value
- string
Framework
Add the reference only when targeting a specific framework.
public string? Framework { get; init; }
Property Value
- string
Interactive
Allows the command to stop and wait for user input or action (for example to complete authentication).
public bool? Interactive { get; init; }
Property Value
- bool?
NoRestore
Add the reference without performing restore preview and compatibility check.
public bool? NoRestore { get; init; }
Property Value
- bool?
PackageDirectory
The directory to restore packages to.
public string? PackageDirectory { get; init; }
Property Value
- string
Prerelease
Allows prerelease packages to be installed.
public bool? Prerelease { get; init; }
Property Value
- bool?
Project
The project file to operate on. If a file is not specified, the command will search the current directory for one.
public string? Project { get; init; }
Property Value
- string
Source
The NuGet package source to use during the restore.
public string? Source { get; init; }
Property Value
- string
Version
The version of the package to add.
public string? Version { get; init; }
Property Value
- string
Methods
ToArguments()
Converts these options to individual command-line arguments, in schema order.
public IReadOnlyList<string> ToArguments()
Returns
- IReadOnlyList<string>
The arguments. Each option name and each value is a separate element, so values need no quoting.