diff --git a/src/NfcAime.Dll/MainDll.cs b/src/NfcAime.Dll/MainDll.cs index 9edbe76..fe99526 100644 --- a/src/NfcAime.Dll/MainDll.cs +++ b/src/NfcAime.Dll/MainDll.cs @@ -1,4 +1,5 @@ using System; +using System.Reflection; using System.Runtime.InteropServices; using System.Threading; @@ -21,6 +22,15 @@ namespace NfcAime.Dll { { AllocConsole(); + // 读取如 "1.0.0-a1b2c3d-master" 这种详细版本信息 + var versionString = Assembly.GetExecutingAssembly() + .GetCustomAttribute()? + .InformationalVersion; + + Console.WriteLine($"PN532 Aime Reader - Version {versionString}"); + Console.WriteLine("Make With Love By ZCROM - FROM MikuNet"); + Console.WriteLine("---------------------------------------------"); + Console.WriteLine($"{Config.ReaderCOM} Baud:{Config.ReaderBaud} Mode:{(Config.IDmMode == 1 ? "IDmMode" : "AccessCodeMode")}"); reader = new AimeReader(port: Config.ReaderCOM, baud: Config.ReaderBaud); return 0; } diff --git a/src/NfcAime.Dll/NfcAime.Dll.csproj b/src/NfcAime.Dll/NfcAime.Dll.csproj index 6d16c89..67fe42d 100644 --- a/src/NfcAime.Dll/NfcAime.Dll.csproj +++ b/src/NfcAime.Dll/NfcAime.Dll.csproj @@ -157,4 +157,61 @@ + + + + + + + + 1.0.0 + + $([System.Text.RegularExpressions.Regex]::Replace($(GitBaseVersion), `^v`, ``)) + + + + + + + + + + + + + + + + + + + + + + unknown + local + 0 + + + + + + + <_Parameter1>$(GitBaseVersion).$(GitPatchCount) + + + <_Parameter1>$(GitBaseVersion).$(GitPatchCount) + + + + <_Parameter1>$(GitBaseVersion).$(GitPatchCount)-$(GitBranchName)-$(GitCommitHash) + + + + + + + + + \ No newline at end of file diff --git a/src/NfcAime.Dll/Properties/AssemblyInfo.cs b/src/NfcAime.Dll/Properties/AssemblyInfo.cs index c8d9bc0..83fc604 100644 --- a/src/NfcAime.Dll/Properties/AssemblyInfo.cs +++ b/src/NfcAime.Dll/Properties/AssemblyInfo.cs @@ -30,6 +30,4 @@ using System.Runtime.InteropServices; // // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: -// [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.0.0")] -[assembly: AssemblyFileVersion("1.0.0.0")] \ No newline at end of file +// [assembly: AssemblyVersion("1.0.*")] \ No newline at end of file