From 820ce1fbe7fca16092ac0ed46ed200a42219f02e Mon Sep 17 00:00:00 2001 From: Ayende Rahien Date: Sat, 26 Sep 2009 20:46:19 +0300 Subject: [PATCH 1/3] Adding git commit to the generated output --- psake_ext.ps1 | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/psake_ext.ps1 b/psake_ext.ps1 index 109b4cdd..9fe63723 100644 --- a/psake_ext.ps1 +++ b/psake_ext.ps1 @@ -1,3 +1,9 @@ +function Get-Git-Commit +{ + $gitLog = git log --oneline -1 + return $gitLog.Split(' ')[0] +} + function Generate-Assembly-Info { param( @@ -10,7 +16,7 @@ param( [string]$version, [string]$file = $(throw "file is a required parameter.") ) - + $commit = Get-Git-Commit $asmInfo = "using System; using System.Reflection; using System.Runtime.CompilerServices; @@ -24,7 +30,7 @@ using System.Runtime.InteropServices; [assembly: AssemblyProductAttribute(""$product"")] [assembly: AssemblyCopyrightAttribute(""$copyright"")] [assembly: AssemblyVersionAttribute(""$version"")] -[assembly: AssemblyInformationalVersionAttribute(""$version"")] +[assembly: AssemblyInformationalVersionAttribute(""$version / $commit"")] [assembly: AssemblyFileVersionAttribute(""$version"")] [assembly: AssemblyDelaySignAttribute(false)] " From f53c6dc8b1c78be7506076410873c5bdcadd795d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20H=F6lbling?= Date: Fri, 9 Oct 2009 10:56:48 +0200 Subject: [PATCH 2/3] Modified AsmInfo generation to always output UTF-8 --- psake_ext.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/psake_ext.ps1 b/psake_ext.ps1 index 9fe63723..69a86743 100644 --- a/psake_ext.ps1 +++ b/psake_ext.ps1 @@ -42,5 +42,5 @@ using System.Runtime.InteropServices; [System.IO.Directory]::CreateDirectory($dir) } Write-Host "Generating assembly info file: $file" - Write-Output $asmInfo > $file + out-file -filePath $file -encoding UTF8 -inputObject $asmInfo } \ No newline at end of file From ef659c075982661d6189a9fc533c2cbfb12a3700 Mon Sep 17 00:00:00 2001 From: Ayende Rahien Date: Thu, 22 Oct 2009 15:16:35 +0200 Subject: [PATCH 3/3] Fixing warning for assembly version --- Rhino.Mocks.Tests.Model/Rhino.Mocks.Tests.Model.csproj | 1 + Rhino.Mocks.Tests/Rhino.Mocks.Tests.csproj | 1 + Rhino.Mocks/Rhino.Mocks.csproj | 1 + 3 files changed, 3 insertions(+) diff --git a/Rhino.Mocks.Tests.Model/Rhino.Mocks.Tests.Model.csproj b/Rhino.Mocks.Tests.Model/Rhino.Mocks.Tests.Model.csproj index 5936509e..db06082b 100644 --- a/Rhino.Mocks.Tests.Model/Rhino.Mocks.Tests.Model.csproj +++ b/Rhino.Mocks.Tests.Model/Rhino.Mocks.Tests.Model.csproj @@ -23,6 +23,7 @@ DEBUG;TRACE prompt 4 + 1607 pdbonly diff --git a/Rhino.Mocks.Tests/Rhino.Mocks.Tests.csproj b/Rhino.Mocks.Tests/Rhino.Mocks.Tests.csproj index 23879b6c..1300e17b 100644 --- a/Rhino.Mocks.Tests/Rhino.Mocks.Tests.csproj +++ b/Rhino.Mocks.Tests/Rhino.Mocks.Tests.csproj @@ -49,6 +49,7 @@ 4 false Full + 1607 ..\..\Build\Tests\Release\ diff --git a/Rhino.Mocks/Rhino.Mocks.csproj b/Rhino.Mocks/Rhino.Mocks.csproj index d8e3d3d4..81ab8935 100644 --- a/Rhino.Mocks/Rhino.Mocks.csproj +++ b/Rhino.Mocks/Rhino.Mocks.csproj @@ -39,6 +39,7 @@ true 4 true + 1607 bin\Release\