Modernize versioning and display in app and build output
- Switch to explicit "3.2.0" next-version in GitVersion.yml - Update NuGet packages and set assembly name to "ImageCatalog" - Add MSBuild target to rename published exe with year and version - Add AppVersion property to DataModel, set via IVersionProvider - Replace static version label with data-bound versionLabel in UI - Remove manual version label logic from MainForm - Update DI to inject IVersionProvider into DataModel - Ensures UI always shows correct version and builds are versioned
This commit is contained in:
parent
509d5357a8
commit
69fdf01de3
6 changed files with 106 additions and 21 deletions
|
|
@ -32,7 +32,7 @@ public partial class MainForm
|
|||
private readonly PicSettings _picSettings;
|
||||
|
||||
public MainForm(DataModel model, ImageCreationStuff imageCreationStuff, PicSettings picSettings,
|
||||
ParametriSetup parametriSetup, ILogger<MainForm> logger, IVersionProvider versionProvider)
|
||||
ParametriSetup parametriSetup, ILogger<MainForm> logger)
|
||||
{
|
||||
Model = model;
|
||||
_parametriSetup = parametriSetup;
|
||||
|
|
@ -55,8 +55,7 @@ public partial class MainForm
|
|||
btnOpenSourceFolder.Click += BtnOpenSourceFolder_Click;
|
||||
btnOpenDestFolder.Click += BtnOpenDestFolder_Click;
|
||||
|
||||
var versionString = versionProvider?.GetVersionString() ?? "0.0.0";
|
||||
_Label27.Text = $"Version: {versionString}";
|
||||
// Version label is data-bound to DataModel.AppVersion; DataModel is populated with the version via DI
|
||||
}
|
||||
|
||||
protected void BindControls()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue