philippgille / hello-netcoreapp

Basic .NET Core console application with additional scripts and files for building the app and creating release artifacts for a framework-dependent deployment, self-contained deployment, Docker image, Chocolatey package and AppImage
GNU General Public License v3.0
6 stars 5 forks source link

Add versioning #10

Closed philippgille closed 6 years ago

philippgille commented 7 years ago

Currently everything is 0.1.0 and needs to be changed manually. It should be possible to just have a VERSION file or environment variable or something, that every build script, Dockerfile, Chocolatey nuspec etc. reads and uses when building.

philippgille commented 7 years ago

Maybe a script (both Bash and PowerShell) is needed that reads the version file / environment variable and then replaces old versions in files like the Chocolatey nuspec.

philippgille commented 7 years ago

Note: We also want to have the version in the artifacts' file names, so the build scripts need to incorporate the version as well.

philippgille commented 6 years ago

AppVeyor offers file patching, so I thought maybe we should add a version to the *.csproj, so that the resulting DLL has the correct version as well. But when adding a PackageVersion to the *.csproj and building the project, the resulting DLL doesn't have the used number as Product version in its properties. Maybe it's just for NuGet packages?

So maybe leave the *.csproj out and only change the version in those files where a version already exists.