2017-02-10 18 views
0

これは私が実行しようとしている私のビルド後のスクリプトです:

powershell.exe -ExecutionPolicy Bypass -NoLogo -NonInteractive -NoProfile -Command "Compress-Archive -LiteralPath "$(BuiltOuputPath)" -CompressionLevel Optimal -DestinationPath "$(BuiltOuputPath)_$(Get-Date -Format yyyyMMddTHHmm).zip""

問題はこの部分である:$(Get-Date -Format yyyyMMddTHHmm)

Visual Studioは、空の文字列に置き換えられます。それを防ぐ方法は?どのように$符号を逃してPowerShellに渡すのですか?

答えて

0

「何でも」+「_」+ $(Get-Date -Format yyyyMMddTHHmm)はどうですか?

関連する問題