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

NuGet cmdLine 3.6 beta does not honor -Prop Configuration = Release #3432

Closed
TheBigRic opened this Issue Sep 12, 2016 · 4 comments

Comments

Projects
None yet
3 participants
@TheBigRic

TheBigRic commented Sep 12, 2016

I used NuGet 3.3 before for creating packages using the commandline with this command:

nuget pack %project_file% -Build -Symbols 
   -IncludeReferencedProjects -Properties Configuration=Release

Because of this issue #1922, I tried to use 3.5 RC1, but this gave me still some problems, so I decided to try 3.6. This builded the project in Debug and then tried to package (zip) the files from the \bin\release folder, which was empty. Sometimes it failed, Other times it succeeded, however looking in the created package, it packed only some default xml files and nuspec file.

I got this working by removing -Properties Configuration=Release from the commandline and change my .csproj to let the default build config point to Release:

<Configuration Condition=" '$(Configuration)' == '' ">Release</Configuration>
@rrelyea

This comment has been minimized.

Show comment
Hide comment
@rrelyea

rrelyea Sep 12, 2016

Contributor

please investigate

Contributor

rrelyea commented Sep 12, 2016

please investigate

@rohit21agrawal

This comment has been minimized.

Show comment
Hide comment
@rohit21agrawal

rohit21agrawal Sep 12, 2016

Contributor

@TheBigRic could you share more details of the kind of project it was? or even better, could you attach a small repro project so I am able to repro this issue on my end?

Contributor

rohit21agrawal commented Sep 12, 2016

@TheBigRic could you share more details of the kind of project it was? or even better, could you attach a small repro project so I am able to repro this issue on my end?

@TheBigRic

This comment has been minimized.

Show comment
Hide comment
@TheBigRic

TheBigRic Sep 13, 2016

Nuget.Repro.zip

I attached a zip file which contains 2 solutions:

  1. Default build config = debug
  2. Default build config = release

Solution 1 has this config in de csproj files:

<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>

Solution 2 has this config in de csproj files:

<Configuration Condition=" '$(Configuration)' == '' ">Release</Configuration>

Both solutions contain 2 batch files for creating the package. One fails, the other succeeds.
The only differ in this line:

%nuget% pack %project_file% -Build -IncludeReferencedProjects -Prop Configuration=Release
%nuget% pack %project_file% -Build -IncludeReferencedProjects

I created 2 solutions to proof the problem exists in both release and debug environments

TheBigRic commented Sep 13, 2016

Nuget.Repro.zip

I attached a zip file which contains 2 solutions:

  1. Default build config = debug
  2. Default build config = release

Solution 1 has this config in de csproj files:

<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>

Solution 2 has this config in de csproj files:

<Configuration Condition=" '$(Configuration)' == '' ">Release</Configuration>

Both solutions contain 2 batch files for creating the package. One fails, the other succeeds.
The only differ in this line:

%nuget% pack %project_file% -Build -IncludeReferencedProjects -Prop Configuration=Release
%nuget% pack %project_file% -Build -IncludeReferencedProjects

I created 2 solutions to proof the problem exists in both release and debug environments

@rohit21agrawal

This comment has been minimized.

Show comment
Hide comment
@rohit21agrawal

rohit21agrawal Sep 14, 2016

Contributor

@TheBigRic thanks for the repro! I am investigating this as I am typing this, and will get back to you soon.

Contributor

rohit21agrawal commented Sep 14, 2016

@TheBigRic thanks for the repro! I am investigating this as I am typing this, and will get back to you soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment