Publish can skip Build
This commit is contained in:
parent
090336d785
commit
ded82caccd
4 changed files with 68 additions and 30 deletions
|
@ -28,6 +28,7 @@ namespace Microsoft.DotNet.Tools.Publish
|
|||
var configuration = app.Option("-c|--configuration <CONFIGURATION>", "Configuration under which to build", CommandOptionType.SingleValue);
|
||||
var projectPath = app.Argument("<PROJECT>", "The project to publish, defaults to the current directory. Can be a path to a project.json or a project directory");
|
||||
var nativeSubdirectories = app.Option("--native-subdirectory", "Temporary mechanism to include subdirectories from native assets of dependency packages in output", CommandOptionType.NoValue);
|
||||
var noBuild = app.Option("--no-build", "Do not build projects before publishing", CommandOptionType.NoValue);
|
||||
|
||||
app.OnExecute(() =>
|
||||
{
|
||||
|
@ -41,6 +42,7 @@ namespace Microsoft.DotNet.Tools.Publish
|
|||
publish.NativeSubdirectories = nativeSubdirectories.HasValue();
|
||||
publish.ProjectPath = projectPath.Value;
|
||||
publish.VersionSuffix = versionSuffix.Value();
|
||||
publish.ShouldBuild = !noBuild.HasValue();
|
||||
|
||||
if (string.IsNullOrEmpty(publish.ProjectPath))
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue