Skip to content

When GitVersion is not run, the SolutionVersion.cs file is not generated #211

@corbob

Description

@corbob

Checklist

  • I confirm there are no unresolved issues reported on the Chocolatey Status page.
  • I have verified this is the correct repository for opening this issue.
  • I have verified no other issues exist related to my problem.
  • I have verified this is not an issue for a specific package.
  • I have verified this issue is not security related.
  • I confirm I am using official, and not unofficial, or modified, Chocolatey products.

What You Are Seeing?

Attempted to build Chocolatey/choco in a way that GitVersion did not work. This resulted in the build failing as it did not have a SolutionVersion.cs file.

What is Expected?

Builds should succeed, even if GitVersion is not run.

How Did You Get This To Happen?

In the Chocolatey/choco repository run:

  1. ./build.bat --ShouldRunGitVersion=false
  2. Note that the build fails.

System Details

  • Operating System: Windows 11
  • Windows PowerShell version: 5.1
  • Chocolatey CLI Version: 2.4.3
  • Chocolatey Licensed Extension version: N/A
  • Chocolatey License type:
  • Terminal/Emulator:

Installed Packages

N/A

Output Log

==================================================
============= WRAP POWERSHELL SCRIPT =============
==================================================
calling "C:\code\ch\build.ps1" with args --ShouldRunGitVersion=false
Preparing to run build script...
Running build script...
(4430,12): warning CS1701: Assuming assembly reference 'Newtonsoft.Json, Version=11.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' used by 'Cake.Json' matches identity 'Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' of 'Newtonsoft.Json', you may need to supply runtime policy
(4436,12): warning CS1701: Assuming assembly reference 'Newtonsoft.Json, Version=11.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' used by 'Cake.Json' matches identity 'Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' of 'Newtonsoft.Json', you may need to supply runtime policy
C:/code/ch/tools/Chocolatey.Cake.Recipe.0.30.1/Content/build.cake(245,13): warning CS0618: 'CustomProjectParserResult.OutputPath' is obsolete: 'Use OutputPaths instead for multi-targeting support'
C:/code/ch/tools/Chocolatey.Cake.Recipe.0.30.1/Content/build.cake(247,44): warning CS0618: 'CustomProjectParserResult.OutputPath' is obsolete: 'Use OutputPaths instead for multi-targeting support'
C:/code/ch/tools/Chocolatey.Cake.Recipe.0.30.1/Content/build.cake(387,36): warning CS0618: 'CustomProjectParserResult.OutputPath' is obsolete: 'Use OutputPaths instead for multi-targeting support'
C:/code/ch/tools/Chocolatey.Cake.Recipe.0.30.1/Content/build.cake(398,32): warning CS0618: 'CustomProjectParserResult.OutputPath' is obsolete: 'Use OutputPaths instead for multi-targeting support'
C:/code/ch/tools/Chocolatey.Cake.Recipe.0.30.1/Content/build.cake(406,32): warning CS0618: 'CustomProjectParserResult.OutputPath' is obsolete: 'Use OutputPaths instead for multi-targeting support'
C:/code/ch/tools/Chocolatey.Cake.Recipe.0.30.1/Content/build.cake(451,29): warning CS0618: 'CustomProjectParserResult.OutputPath' is obsolete: 'Use OutputPaths instead for multi-targeting support'
C:/code/ch/tools/Chocolatey.Cake.Recipe.0.30.1/Content/build.cake(452,36): warning CS0618: 'CustomProjectParserResult.OutputPath' is obsolete: 'Use OutputPaths instead for multi-targeting support'
Using Local Build Provider...
Testing to see if valid git repository for LocalBuild setup...
Unable to locate git repository, setting default values for repository properties...
NuGet Sources configured using default values.
defaultPushSourceUrl: [NULL]
Using local Unofficial Strong Name Key...
Setting up tools...
Resolving Visual Studio products without using a version range.
Found MSBuild Tool: C:/Program Files/Microsoft Visual Studio/2022/Community/MSBuild/Current/Bin/amd64/MSBuild.exe
Printing Build Parameters...
------------------------------------------------------------------------------------------
BranchType: Unknown
BranchName: unknown
BuildAgentOperatingSystem: Windows
BuildCounter: -1
BuildDirectoryPath: C:/code/ch/code_drop
BuildProviderRepositoryName: Local
ChocolateyNupkgGlobbingPattern: /**/chocolatey*.nupkg
ChocolateyNuspecGlobbingPattern: /**/*.nuspec
Configuration: Release
DependencyCheckDbDriverName: com.microsoft.sqlserver.jdbc.SQLServerDriver
ForceContinuousIntegration: False
IntegrationTestAssemblyFilePattern: /**/*[tT]ests.[iI]ntegration.dll
IntegrationTestAssemblyProjectPattern: /**/*[tT]ests.[iI]ntegration.csproj
IsLocalBuild: True
IsPullRequest: False
IsTagged: False
NuGetNupkgGlobbingPattern: /**/*.nupkg
NuGetNuspecGlobbingPattern: /**/*.nuspec
NuGetSources: https://www.nuget.org/api/v2/, https://api.nuget.org/v3/index.json
ObfuscateAssembly: False
PreferDotNetGlobalToolUsage: False
PrepareLocalRelease: False
ProductName: Chocolatey
ProductDescription: chocolatey is a product of Chocolatey Software, Inc. - All Rights Reserved.
ProductCopyright: Copyright c 2017 - 2025 Chocolatey Software, Inc. Copyright c 2011 - 2017, RealDimensions Software, LLC - All Rights Reserved.
ProductComVisible: False
ProductClsCompliant: False
ProductCompany: Chocolatey Software, Inc.
ProductCustomAttributes: No Product Custom Attributes being used
ProductTrademark: Chocolatey - Chocolatey Software, Inc.
RepositoryHostedInGitLab: False
RepositoryName: choco
RepositoryOwner: chocolatey
RestorePackagesDirectory: [NULL]
ShouldAuthenticodeSignMsis: True
ShouldAuthenticodeSignOutputAssemblies: True
ShouldVerifyPowerShellScripts: True
ShouldAuthenticodeSignPowerShellScripts: True
ShouldBuildMsi: False
ShouldBuildNuGetSourcePackage: False
ShouldDownloadFullReleaseNotes: False
ShouldDownloadMilestoneReleaseNotes: False
ShouldGenerateSolutionVersionCSharpFile: True
ShouldObfuscateOutputAssemblies: True
ShouldPostToDiscord: True
ShouldPostToMastodon: True
ShouldPostToSlack: True
ShouldPostToTwitter: True
ShouldPublishAwsLambdas: False
ShouldPublishPreReleasePackages: True
ShouldPublishReleasePackages: True
ShouldReportCodeCoverageMetrics: True
ShouldReportUnitTestResults: True
ShouldRunAnalyze: True
ShouldRunChocolatey: True
ShouldRunDependencyCheck: False
ShouldRunDocker: True
ShouldRunDotNetFormat: True
ShouldRunDotNetPack: False
ShouldRunDotNetTest: True
ShouldRunGitReleaseManager: False
ShouldRunGitVersion: False
ShouldRunILMerge: True
ShouldRunInspectCode: True
ShouldRunNuGet: True
ShouldRunNUnit: True
ShouldRunOpenCover: True
ShouldRunReportGenerator: True
ShouldRunReportUnit: True
ShouldRunSonarQube: False
ShouldRunTests: True
ShouldRunTransifex: False
ShouldRunxUnit: True
ShouldRunPSScriptAnalyzer: True
ShouldStrongNameOutputAssemblies: True
ShouldStrongNameSignDependentAssemblies: False
SolutionDirectoryPath: C:/code/ch/src/chocolatey
SolutionFilePath: C:/code/ch/src/chocolatey.sln
SonarQubeId: ch
SonarQubeUrl: [NULL]
SourceDirectoryPath: C:/code/ch/src
StrongNameDependentAssembliesInputPath: src/packages
Target: Default
TestDirectoryPath: src
TestExecutionType: unit
TreatWarningsAsErrors: False
UnitTestAssemblyFilePattern: /**/*.[tT]ests/**/*.[tT]ests.dll
UnitTestAssemblyProjectPattern: /**/*.[tT]ests/**/*.[tT]ests.csproj
UseChocolateyGuiStrongNameKey: False
------------------------------------------------------------------------------------------

----------------------------------------
Setup
----------------------------------------
  ____  _                          _         _                
 / ___|| |__    ___    ___   ___  | |  __ _ | |_   ___  _   _ 
| |    | '_ \  / _ \  / __| / _ \ | | / _` || __| / _ \| | | |
| |___ | | | || (_) || (__ | (_) || || (_| || |_ |  __/| |_| |
 \____||_| |_| \___/  \___| \___/ |_| \__,_| \__| \___| \__, |
                                                        |___/ 

Starting Setup...
Running GitVersion is not enabled, so returning default values...
Building version 0.1.0-alpha-20220317-13 of Chocolatey (Release, Default) using version 0.38.5.0 of Cake, and version 0.30.1 of Chocolatey.Cake.Recipe. (IsTagged: False)

========================================
Print-CI-Provider-Environment-Variables
========================================
No environment variables is available for current provider.

========================================
Clean
========================================
Cleaning...

========================================
Restore
========================================
Restoring src/chocolatey.sln...
MSBuild auto-detection: using msbuild version '17.14.10.27608' from 'C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\bin'.
All packages listed in packages.config are already installed.
  CACHE https://api.nuget.org/v3/vulnerabilities/index.json
  CACHE https://api.nuget.org/v3-vulnerabilities/2025.05.28.05.39.59/vulnerability.base.json
  CACHE https://api.nuget.org/v3-vulnerabilities/2025.05.28.05.39.59/2025.06.03.17.40.29/vulnerability.update.json

========================================
Build
========================================
Building src/chocolatey.sln
MSBuild version 17.14.10+8b8e13593 for .NET Framework
Build started 6/3/2025 11:22:27 PM.

     1>Project "C:\code\ch\src\chocolatey.sln" on node 1 (Build target(s)).
     1>ValidateSolutionConfiguration:
         Building solution configuration "Release|Any CPU".
       ValidateProjects:
         The project "chocolatey.install" is not selected for building in solution configuration "Release|Any CPU".
     1>Project "C:\code\ch\src\chocolatey.sln" (1) is building "C:\code\ch\src\chocolatey.console\chocolatey.console.csproj" (2) on node 1 (default targets).
     2>CopyEditorConfig:
         Copying the .editorconfig file from 'C:\code\ch\src\packages\Chocolatey.BestPractices.1.0.0\build\/.editorconfig' to 'C:\code\ch\src\chocolatey.console/../.editorconfig'
     2>Project "C:\code\ch\src\chocolatey.console\chocolatey.console.csproj" (2) is building "C:\code\ch\src\chocolatey.resources\chocolatey.resources.csproj" (3:2) on node 1 (default targets).
     3>GenerateTargetFrameworkMonikerAttribute:
       Skipping target "GenerateTargetFrameworkMonikerAttribute" because all output files are up-to-date with respect to the input files.
       CoreCompile:
         C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\Roslyn\csc.exe /noconfig /nowarn:1701,1702 /fullpaths /nostdlib+ /errorreport:prompt /warn:4 /define:TRACE /highentropyva+ /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.8\mscorlib.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.8\System.Core.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.8\System.dll" /debug- /filealign:512 /optimize+ /out:obj\Release\chocolatey.resources.dll /subsystemversion:6.00 /resource:helpers\chocolateyInstaller.psm1,chocolatey.resources.helpers.chocolateyInstaller.psm1 /resource:helpers\chocolateyProfile.psm1,chocolatey.resources.helpers.chocolateyProfile.psm1 /resource:helpers\functions\Format-FileSize.ps1,chocolatey.resources.helpers.functions.Format-FileSize.ps1 /resource:helpers\functions\Get-CheckSumValid.ps1,chocolatey.resources.helpers.functions.Get-CheckSumValid.ps1 /resource:helpers\functions\Get-ChocolateyConfigValue.ps1,chocolatey.resources.helpers.functions.Get-ChocolateyConfigValue.ps1 /resource:helpers\functions\Get-ChocolateyPath.ps1,chocolatey.resources.helpers.functions.Get-ChocolateyPath.ps1 /resource:helpers\functions\Get-ChocolateyUnzip.ps1,chocolatey.resources.helpers.functions.Get-ChocolateyUnzip.ps1 /resource:helpers\functions\Get-ChocolateyWebFile.ps1,chocolatey.resources.helpers.functions.Get-ChocolateyWebFile.ps1 /resource:helpers\functions\Get-FtpFile.ps1,chocolatey.resources.helpers.functions.Get-FtpFile.ps1 /resource:helpers\functions\Get-OSArchitectureWidth.ps1,chocolatey.resources.helpers.functions.Get-OSArchitectureWidth.ps1 /resource:helpers\functions\Get-UACEnabled.ps1,chocolatey.resources.helpers.functions.Get-UACEnabled.ps1 /resource:helpers\functions\Get-VirusCheckValid.ps1,chocolatey.resources.helpers.functions.Get-VirusCheckValid.ps1 /resource:helpers\functions\Get-WebFile.ps1,chocolatey.resources.helpers.functions.Get-WebFile.ps1 /resource:helpers\functions\Get-WebHeaders.ps1,chocolatey.resources.helpers.functions.Get-WebHeaders.ps1 /resource:helpers\functions\Install-ChocolateyEnvironmentVariable.ps1,chocolatey.resources.helpers.functions.Install-ChocolateyEnvironmentVariable.ps1 /resource:helpers\functions\Install-ChocolateyExplorerMenuItem.ps1,chocolatey.resources.helpers.functions.Install-ChocolateyExplorerMenuItem.ps1 /resource:helpers\functions\Install-ChocolateyFileAssociation.ps1,chocolatey.resources.helpers.functions.Install-ChocolateyFileAssociation.ps1 /resource:helpers\functions\Install-ChocolateyInstallPackage.ps1,chocolatey.resources.helpers.functions.Install-ChocolateyInstallPackage.ps1 /resource:helpers\functions\Install-ChocolateyPackage.ps1,chocolatey.resources.helpers.functions.Install-ChocolateyPackage.ps1 /resource:helpers\functions\Install-ChocolateyPinnedTaskBarItem.ps1,chocolatey.resources.helpers.functions.Install-ChocolateyPinnedTaskBarItem.ps1 /resource:helpers\functions\Install-ChocolateyPowershellCommand.ps1,chocolatey.resources.helpers.functions.Install-ChocolateyPowershellCommand.ps1 /resource:helpers\functions\Install-ChocolateyShortcut.ps1,chocolatey.resources.helpers.functions.Install-ChocolateyShortcut.ps1 /resource:helpers\functions\Install-ChocolateyVsixPackage.ps1,chocolatey.resources.helpers.functions.Install-ChocolateyVsixPackage.ps1 /resource:helpers\functions\Install-ChocolateyZipPackage.ps1,chocolatey.resources.helpers.functions.Install-ChocolateyZipPackage.ps1 /resource:helpers\functions\Start-ChocolateyProcessAsAdmin.ps1,chocolatey.resources.helpers.functions.Start-ChocolateyProcessAsAdmin.ps1 /resource:helpers\functions\Uninstall-ChocolateyPackage.ps1,chocolatey.resources.helpers.functions.Uninstall-ChocolateyPackage.ps1 /resource:helpers\functions\UnInstall-ChocolateyZipPackage.ps1,chocolatey.resources.helpers.functions.UnInstall-ChocolateyZipPackage.ps1 /resource:helpers\functions\Install-BinFile.ps1,chocolatey.resources.helpers.functions.Install-BinFile.ps1 /resource:helpers\functions\Uninstall-BinFile.ps1,chocolatey.resources.helpers.functions.Uninstall-BinFile.ps1 /resource:helpers\chocolateyScriptRunner.ps1,chocolatey.resources.helpers.chocolateyScriptRunner.ps1 /resource:helpers\functions\Get-WebFileName.ps1,chocolatey.resources.helpers.functions.Get-WebFileName.ps1 /resource:helpers\functions\Get-ToolsLocation.ps1,chocolatey.resources.helpers.functions.Get-ToolsLocation.ps1 /resource:helpers\ChocolateyTabExpansion.ps1,chocolatey.resources.helpers.ChocolateyTabExpansion.ps1 /resource:helpers\functions\Set-PowerShellExitCode.ps1,chocolatey.resources.helpers.functions.Set-PowerShellExitCode.ps1 /resource:helpers\functions\Install-Vsix.ps1,chocolatey.resources.helpers.functions.Install-Vsix.ps1 /resource:helpers\functions\Uninstall-ChocolateyEnvironmentVariable.ps1,chocolatey.resources.helpers.functions.Uninstall-ChocolateyEnvironmentVariable.ps1 /resource:helpers\functions\Get-UninstallRegistryKey.ps1,chocolatey.resources.helpers.functions.Get-UninstallRegistryKey.ps1 /resource:helpers\functions\Write-FunctionCallLogMessage.ps1,chocolatey.resources.helpers.functions.Write-FunctionCallLogMessage.ps1 /resource:helpers\functions\Get-PackageParameters.ps1,chocolatey.resources.helpers.functions.Get-PackageParameters.ps1 /resource:redirects\choco.exe.ignore,chocolatey.resources.redirects.choco.exe.ignore /resource:tools\checksum.exe.ignore,chocolatey.resources.tools.checksum.exe.ignore /resource:tools\shimgen.exe.ignore,chocolatey.resources.tools.shimgen.exe.ignore /resource:tools\7z.exe.ignore,chocolatey.resources.tools.7z.exe.ignore /resource:LICENSE.txt,chocolatey.resources.LICENSE.txt /resource:tools\checksum.license.txt,chocolatey.resources.tools.checksum.license.txt /resource:tools\shimgen.license.txt,chocolatey.resources.tools.shimgen.license.txt /resource:tools\7zip.license.txt,chocolatey.resources.tools.7zip.license.txt /resource:redirects\choco.exe,chocolatey.resources.redirects.choco.exe /resource:tools\checksum.exe,chocolatey.resources.tools.checksum.exe /resource:tools\shimgen.exe,chocolatey.resources.tools.shimgen.exe /resource:tools\7z.exe,chocolatey.resources.tools.7z.exe /resource:redirects\RefreshEnv.cmd,chocolatey.resources.redirects.RefreshEnv.cmd /resource:tools\checksum.exe.config,chocolatey.resources.tools.checksum.exe.config /resource:tools\7z.dll,chocolatey.resources.tools.7z.dll /resource:tools\7z.exe.manifest,chocolatey.resources.tools.7z.exe.manifest /resource:tools\7z.dll.manifest,chocolatey.resources.tools.7z.dll.manifest /target:library /warnaserror- /utf8output /langversion:7.3 /analyzerconfig:C:\code\ch\src\.editorconfig ..\SolutionVersion.cs ChocolateyResourcesAssembly.cs Properties\AssemblyInfo.cs "obj\Release\.NETFramework,Version=v4.8.AssemblyAttributes.cs"
     3>CSC : error CS2001: Source file 'C:\code\ch\src\chocolatey.resources\..\SolutionVersion.cs' could not be found. [C:\code\ch\src\chocolatey.resources\chocolatey.resources.csproj]
         CompilerServer: server - server processed compilation - chocolatey.resources
     3>Done Building Project "C:\code\ch\src\chocolatey.resources\chocolatey.resources.csproj" (default targets) -- FAILED.
     2>Project "C:\code\ch\src\chocolatey.console\chocolatey.console.csproj" (2) is building "C:\code\ch\src\Chocolatey.PowerShell\Chocolatey.PowerShell.csproj" (5:2) on node 1 (default targets).
     5>GenerateTargetFrameworkMonikerAttribute:
       Skipping target "GenerateTargetFrameworkMonikerAttribute" because all output files are up-to-date with respect to the input files.
       CoreCompile:
         C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\Roslyn\csc.exe /noconfig /nowarn:1701,1702 /fullpaths /nostdlib+ /errorreport:prompt /warn:4 /define:TRACE /highentropyva+ /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.8\Microsoft.CSharp.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.8\mscorlib.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.8\System.Core.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.8\System.Data.DataSetExtensions.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.8\System.Data.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.8\System.dll" /reference:C:\code\ch\lib\PowerShell\System.Management.Automation.dll /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.8\System.Net.Http.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.8\System.Xml.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.8\System.Xml.Linq.dll" /debug:pdbonly /filealign:512 /optimize+ /out:obj\Release\Chocolatey.PowerShell.dll /subsystemversion:6.00 /target:library /warnaserror- /utf8output /deterministic+ /langversion:7.3 /analyzerconfig:C:\code\ch\src\.editorconfig Commands\GetEnvironmentVariableCommand.cs Commands\GetEnvironmentVariableNamesCommand.cs Commands\InstallChocolateyPathCommand.cs Commands\SetEnvironmentVariableCommand.cs Commands\TestProcessAdminRightsCommand.cs Commands\UninstallChocolateyPathCommand.cs Commands\UpdateSessionEnvironmentCommand.cs Helpers\Elevation.cs Helpers\EnvironmentHelper.cs Helpers\Paths.cs Helpers\ProcessInformation.cs Helpers\PSHelper.cs Properties\AssemblyInfo.cs ..\SolutionVersion.cs Shared\ChocolateyCmdlet.cs Shared\EnvironmentVariables.cs Win32\NativeMethods.cs "obj\Release\.NETFramework,Version=v4.8.AssemblyAttributes.cs"
     5>CSC : error CS2001: Source file 'C:\code\ch\src\Chocolatey.PowerShell\..\SolutionVersion.cs' could not be found. [C:\code\ch\src\Chocolatey.PowerShell\Chocolatey.PowerShell.csproj]
         CompilerServer: server - server processed compilation - Chocolatey.PowerShell
     5>Done Building Project "C:\code\ch\src\Chocolatey.PowerShell\Chocolatey.PowerShell.csproj" (default targets) -- FAILED.
     2>Done Building Project "C:\code\ch\src\chocolatey.console\chocolatey.console.csproj" (default targets) -- FAILED.
     1>Done Building Project "C:\code\ch\src\chocolatey.sln" (Build target(s)) -- FAILED.

Build FAILED.

       "C:\code\ch\src\chocolatey.sln" (Build target) (1) ->
       "C:\code\ch\src\chocolatey.console\chocolatey.console.csproj" (default target) (2) ->
       "C:\code\ch\src\chocolatey.resources\chocolatey.resources.csproj" (default target) (3:2) ->
       (CoreCompile target) -> 
         CSC : error CS2001: Source file 'C:\code\ch\src\chocolatey.resources\..\SolutionVersion.cs' could not be found. [C:\code\ch\src\chocolatey.resources\chocolatey.resources.csproj]


       "C:\code\ch\src\chocolatey.sln" (Build target) (1) ->
       "C:\code\ch\src\chocolatey.console\chocolatey.console.csproj" (default target) (2) ->
       "C:\code\ch\src\Chocolatey.PowerShell\Chocolatey.PowerShell.csproj" (default target) (5:2) ->
         CSC : error CS2001: Source file 'C:\code\ch\src\Chocolatey.PowerShell\..\SolutionVersion.cs' could not be found. [C:\code\ch\src\Chocolatey.PowerShell\Chocolatey.PowerShell.csproj]

    0 Warning(s)
    2 Error(s)

Time Elapsed 00:00:00.49

----------------------------------------
Teardown
----------------------------------------
Starting Teardown...
Finished running tasks.
==================================================

Additional Context

It appears that we should not be returning early, and instead continue processing things.

Currently we return the version if we're told not to run GitVersion:

, then we return that same version if GitVersion fails for some reason: . But we don't determine if we should create the SolutionVersion.cs file until much later:
if (BuildParameters.ShouldGenerateSolutionVersionCSharpFile)

Metadata

Metadata

Assignees

Labels

3 - ReviewCode has been added, and is available for review as a pull request.BugIssues where something has happened which was not expected or intended.

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions