File tree Expand file tree Collapse file tree 1 file changed +12
-18
lines changed
Tasks/UnityBuild/UnityBuildV3 Expand file tree Collapse file tree 1 file changed +12
-18
lines changed Original file line number Diff line number Diff line change @@ -261,15 +261,12 @@ export class UnityVersioning {
261261 projectVersioningCommitChangesMessageVariableName
262262 ) ! ;
263263
264- commitMessage = commitMessage . replace (
265- "{{bundleVersion}}" ,
266- `${ bundleVersion . major } .${ bundleVersion . minor } .${ bundleVersion . patch } `
267- ) ;
268-
269- commitMessage = commitMessage . replace (
270- "{{buildNumber}}" ,
271- buildCode . toString ( )
272- ) ;
264+ commitMessage = commitMessage
265+ . replace (
266+ / { { bundleVersion} } / g,
267+ `${ bundleVersion . major } .${ bundleVersion . minor } .${ bundleVersion . patch } `
268+ )
269+ . replace ( / { { buildNumber} } / g, buildCode . toString ( ) ) ;
273270
274271 tl . execSync ( "git" , [ "config" , "user.name" , commitChangesUserName ] ) ;
275272 tl . execSync ( "git" , [ "config" , "user.email" , commitChangesUserMail ] ) ;
@@ -283,15 +280,12 @@ export class UnityVersioning {
283280 true
284281 ) ! ;
285282
286- gitTag = createTagPattern . replace (
287- "{{bundleVersion}}" ,
288- `${ bundleVersion . major } .${ bundleVersion . minor } .${ bundleVersion . patch } `
289- ) ;
290-
291- gitTag = createTagPattern . replace (
292- "{{buildNumber}}" ,
293- buildCode . toString ( )
294- ) ;
283+ gitTag = createTagPattern
284+ . replace (
285+ / { { bundleVersion} } / g,
286+ `${ bundleVersion . major } .${ bundleVersion . minor } .${ bundleVersion . patch } `
287+ )
288+ . replace ( / { { buildNumber} } / g, buildCode . toString ( ) ) ;
295289
296290 tl . execSync ( "git" , [ "tag" , gitTag ] ) ;
297291 }
You can’t perform that action at this time.
0 commit comments