From 9eafe478fc9384647ce12ffc4d0bf3436fac3435 Mon Sep 17 00:00:00 2001 From: Terry MacDonald Date: Thu, 30 Sep 2021 10:26:17 +1300 Subject: [PATCH] Revised build versioning Changed the build versioning to use an incrementing build version per build (and revision version per release build) as per https://stackoverflow.com/questions/826777/how-to-have-an-auto-incrementing-version-number-visual-studio. This uses an AssemblyInfo.tt T4 template to customise the versioning so that the application version can be set using the AssemblyVersion variable within the Visual Studio application properties. This makes it dead easy to change! The Wix Program.wxs was also changed to use that new 4 digit version number as the versioning, which should help immensely with beta testing updates. No more asking people to uninstall the previous version as the new build will automatically upgrade the earlier version! --- DisplayMagician/DisplayMagician.csproj | 14 +- DisplayMagician/Program.cs | 5 +- DisplayMagician/Properties/AssemblyInfo.cs | 33 ++--- .../Properties/AssemblyInfo.cs.old | 44 +++++++ DisplayMagician/Properties/AssemblyInfo.tt | 57 +++++++++ .../UIForms/StartMessageForm.Designer.cs | 99 +++++++++++++++ DisplayMagician/UIForms/StartMessageForm.cs | 37 ++++++ DisplayMagician/UIForms/StartMessageForm.resx | 120 ++++++++++++++++++ .../DisplayMagicianFilesFragment.wxs | 2 +- .../Includes/DisplayMagicianVariables.wxi | 11 -- DisplayMagicianSetup/Product.wxs | 10 +- 11 files changed, 390 insertions(+), 42 deletions(-) create mode 100644 DisplayMagician/Properties/AssemblyInfo.cs.old create mode 100644 DisplayMagician/Properties/AssemblyInfo.tt create mode 100644 DisplayMagician/UIForms/StartMessageForm.Designer.cs create mode 100644 DisplayMagician/UIForms/StartMessageForm.cs create mode 100644 DisplayMagician/UIForms/StartMessageForm.resx diff --git a/DisplayMagician/DisplayMagician.csproj b/DisplayMagician/DisplayMagician.csproj index 6e5906f..b410972 100644 --- a/DisplayMagician/DisplayMagician.csproj +++ b/DisplayMagician/DisplayMagician.csproj @@ -122,6 +122,7 @@ + True True @@ -168,6 +169,12 @@ ShortcutLibraryForm.cs + + Form + + + StartMessageForm.cs + UserControl @@ -199,7 +206,6 @@ DisplayProfileForm.cs - ResXFileCodeGenerator Language.Designer.cs @@ -234,6 +240,9 @@ ShortcutLibraryForm.cs Designer + + StartMessageForm.cs + StartProgramControl.cs @@ -369,6 +378,9 @@ + + "$(DevEnvDir)TextTransform.exe" -a !!BuildConfiguration!$(Configuration) "$(ProjectDir)Properties\AssemblyInfo.tt" + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/DisplayMagicianSetup/Fragments/DisplayMagicianFilesFragment.wxs b/DisplayMagicianSetup/Fragments/DisplayMagicianFilesFragment.wxs index 076d934..a826797 100644 --- a/DisplayMagicianSetup/Fragments/DisplayMagicianFilesFragment.wxs +++ b/DisplayMagicianSetup/Fragments/DisplayMagicianFilesFragment.wxs @@ -21,7 +21,7 @@ - + diff --git a/DisplayMagicianSetup/Includes/DisplayMagicianVariables.wxi b/DisplayMagicianSetup/Includes/DisplayMagicianVariables.wxi index f03b41c..b298b6a 100644 --- a/DisplayMagicianSetup/Includes/DisplayMagicianVariables.wxi +++ b/DisplayMagicianSetup/Includes/DisplayMagicianVariables.wxi @@ -1,16 +1,5 @@ - - - - - - - - - + - - - + + + - +