From: Paul Durrant Date: Wed, 8 May 2019 14:16:44 +0000 (+0100) Subject: Avoid leading '0's in version.h date values... X-Git-Tag: 9.0.0-rc1~25 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=7639ae38910dcfa05a9568425df683f8be63c1ae;p=pvdrivers%2Fwin%2Fxenbus.git Avoid leading '0's in version.h date values... ... which cause the compiler to think they are octal quantities. Signed-off-by: Paul Durrant --- diff --git a/scripts/genfiles.ps1 b/scripts/genfiles.ps1 index 6adc7f9..d402696 100644 --- a/scripts/genfiles.ps1 +++ b/scripts/genfiles.ps1 @@ -42,9 +42,9 @@ Function Copy-FileWithReplacements { # # Script Body # -$TheYear = Get-Date -UFormat "%Y" -$TheMonth = Get-Date -UFormat "%m" -$TheDay = Get-Date -UFormat "%d" +$TheYear = [int](Get-Date -UFormat "%Y") +$TheMonth = [int](Get-Date -UFormat "%m") +$TheDay = [int](Get-Date -UFormat "%d") $InfArch = @{ "Win32" = "x86"; "x64" = "amd64" } $InfDate = Get-Date -UFormat "%m/%d/%Y"