Created
October 25, 2013 18:01
-
-
Save philcleveland/7159081 to your computer and use it in GitHub Desktop.
Trying to pass variable from TFS to WiX
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
I have a Variable defined in my TFS Build template | |
Name:TFSGenProductVersion | |
Type:String | |
Scope:Sequence | |
Default:"3.1.2" | |
I added this to the wixproj | |
<PropertyGroup Condition=" '$(Configuration)' == 'Debug' "> | |
<DefineConstants>Debug;MyProductVersion=0.0.0.1</DefineConstants> | |
</PropertyGroup> | |
<PropertyGroup Condition=" '$(Configuration)' == 'Release' "> | |
<DefineConstants>MyProductVersion=$(TFSGenProductVersion)</DefineConstants> | |
</PropertyGroup> | |
I added this to the wxs | |
<Product Id="B5F53C50-A6D9-4731-BE9B-AA3B7CF63366" | |
Name="MyApp" | |
Language="1033" | |
Version="$(var.MyProductVersion)" | |
Manufacturer="Me" | |
UpgradeCode="B7CE3354-C478-4E0B-8547-A83AC7F3F77C"> | |
when TFS builds I get the following, so I know the variable is not being passed in. | |
..\Product.wxs (12): The Product/@Version attribute's value cannot be an empty string. If you want the value to be null or empty, simply remove the entire attribute. | |
..\Product.wxs (12): The Product/@Version attribute was not found; it is required. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment