File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -7340,10 +7340,12 @@ class GitAuthHelper {
7340
7340
core.warning(`Failed to remove '${configKey}' from the git config`);
7341
7341
}
7342
7342
}
7343
- const pattern = regexpHelper.escape(configKey);
7344
- yield this.git.submoduleForeach(
7345
- // wrap the pipeline in quotes to make sure it's handled properly by submoduleForeach, rather than just the first part of the pipeline
7346
- `sh -c "git config --local --name-only --get-regexp '${pattern}' && git config --local --unset-all '${configKey}' || :"`, true);
7343
+ if (this.settings.submodules) {
7344
+ const pattern = regexpHelper.escape(configKey);
7345
+ yield this.git.submoduleForeach(
7346
+ // wrap the pipeline in quotes to make sure it's handled properly by submoduleForeach, rather than just the first part of the pipeline
7347
+ `sh -c "git config --local --name-only --get-regexp '${pattern}' && git config --local --unset-all '${configKey}' || :"`, true);
7348
+ }
7347
7349
});
7348
7350
}
7349
7351
}
You can’t perform that action at this time.
0 commit comments