From 4583679a4e8dbfa76efb838f26dede4253c173ec Mon Sep 17 00:00:00 2001 From: Paddy Xu Date: Sun, 2 Sep 2018 15:11:59 +0300 Subject: [PATCH] add version to metadata --- .gitignore | 1 + QuickLook.Plugin.HelloWorld.csproj | 1 + ...etadata.config => QuickLook.Plugin.Metadata.Base.config | 2 +- Scripts/update-version.ps1 | 7 ++++++- 4 files changed, 9 insertions(+), 2 deletions(-) rename QuickLook.Plugin.Metadata.config => QuickLook.Plugin.Metadata.Base.config (88%) diff --git a/.gitignore b/.gitignore index 24fe50e..4289056 100644 --- a/.gitignore +++ b/.gitignore @@ -330,3 +330,4 @@ ASALocalRun/ .mfractor/ /*.qlplugin /GitVersion.cs +/QuickLook.Plugin.Metadata.config diff --git a/QuickLook.Plugin.HelloWorld.csproj b/QuickLook.Plugin.HelloWorld.csproj index 0e5ff6f..cc1bb43 100644 --- a/QuickLook.Plugin.HelloWorld.csproj +++ b/QuickLook.Plugin.HelloWorld.csproj @@ -78,6 +78,7 @@ + Always diff --git a/QuickLook.Plugin.Metadata.config b/QuickLook.Plugin.Metadata.Base.config similarity index 88% rename from QuickLook.Plugin.Metadata.config rename to QuickLook.Plugin.Metadata.Base.config index cb73268..d24f4b9 100644 --- a/QuickLook.Plugin.Metadata.config +++ b/QuickLook.Plugin.Metadata.Base.config @@ -1,6 +1,6 @@ - QuickLook.Plugin.HelloWorld + 0 This plugin does nothing at all. \ No newline at end of file diff --git a/Scripts/update-version.ps1 b/Scripts/update-version.ps1 index e7e09fa..276f799 100644 --- a/Scripts/update-version.ps1 +++ b/Scripts/update-version.ps1 @@ -10,4 +10,9 @@ using System.Reflection; [assembly: AssemblyInformationalVersion("$revision")] "@ -$text | Out-File $PSScriptRoot\..\GitVersion.cs -Encoding utf8 \ No newline at end of file +$text | Out-File $PSScriptRoot\..\GitVersion.cs -Encoding utf8 + + +$xml = [xml](Get-Content $PSScriptRoot\..\QuickLook.Plugin.Metadata.Base.config) +$xml.Metadata.Version="$revision" +$xml.Save("$PSScriptRoot\..\QuickLook.Plugin.Metadata.config") \ No newline at end of file