Skip to content

Commit

Permalink
important bug fixe for repo passing, #1487
Browse files Browse the repository at this point in the history
Signed-off-by: Michael Kauzmann <[email protected]>
  • Loading branch information
zepumph committed Oct 22, 2024
1 parent 915016f commit 6beacf8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion js/grunt/Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ const assert = require( 'assert' );
require( './checkNodeVersion' );
const registerTasks = require( '../../../perennial-alias/js/grunt/util/registerTasks' );
const gruntSpawn = require( '../../../perennial-alias/js/grunt/util/gruntSpawn' );
const _ = require( 'lodash' );

// Allow other Gruntfiles to potentially handle exiting and errors differently
if ( !global.processEventOptOut ) {
Expand Down Expand Up @@ -52,7 +53,7 @@ module.exports = function( grunt ) {
const args = [ ...currentArgs ];

// Don't duplicate repo arg
!currentArgs.includes( '--repo=' ) && args.push( `--repo=${repo}` );
!_.some( process.argv, arg => arg.startsWith( '--repo=' ) ) && args.push( `--repo=${repo}` );
const isWindows = /^win/.test( process.platform );
gruntSpawn( grunt, isWindows ? 'grunt.cmd' : 'grunt', args, `../${forwardingRepo}`, argsString => {
grunt.log.debug( `running grunt ${argsString} in ../${repo}` );
Expand Down

0 comments on commit 6beacf8

Please sign in to comment.