You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Fixed quite a few bugs in the script: parameter sets not working quite right, not using the Revision part when provided, lots of PowerShell syntax/null ref errors.
- Minor refactorings.
- Got unit test working properly, but still need to add more.
# If we should be using the BuildSystemsBuildId for the Build and Revision.
228
243
if ($BuildSystemsBuildId-gt-1)
229
244
{
230
245
# Use a calculation for the Build and Revision to prevent the Revision value from being too large, and to increment the Build value as the BuildSystemsBuildId continues to grow larger.
# Make sure the Revision version part is not greater than the max allowed value.
257
-
if ($Revision-gt$maxVersionPartValueAllowed)
272
+
if ($revision-gt$maxVersionPartValueAllowed)
258
273
{
259
-
Write-Warning"The Revision value '$Revision' to use for the last part of the version number is greater than the max allowed value of '$maxVersionPartValueAllowed'. The modulus will be used for the revision instead. If this results in your ClickOnce deployment not downloading the latest update and giving an error message like 'Cannot activate a deployment with earlier version than the current minimum required version of the application.' then you will need to increment the Build part of the ClickOnce <ApplicationVersion> value stored in the project file."
260
-
$Revision%=$maxVersionPartValueAllowed
274
+
Write-Warning"The Revision value '$revision' to use for the last part of the version number is greater than the max allowed value of '$maxVersionPartValueAllowed'. The modulus will be used for the revision instead. If this results in your ClickOnce deployment not downloading the latest update and giving an error message like 'Cannot activate a deployment with earlier version than the current minimum required version of the application.' then you will need to increment the Build part of the ClickOnce <ApplicationVersion> value stored in the project file."
275
+
$revision%=$maxVersionPartValueAllowed
261
276
}
262
277
}
263
278
}
264
279
265
280
# Create the version number to use for the ClickOnce version.
266
281
$newMajorMinorBuild="$majorMinor.$build"
267
-
$newVersionNumber="$newMajorMinorBuild.$Revision"
282
+
$newVersionNumber="$newMajorMinorBuild.$revision"
268
283
Write-Output"Updating version number to be '$newVersionNumber'."
0 commit comments