Skip to content

Commit 0252379

Browse files
chusemanarturcic
authored andcommitted
Make sure configFilePath as supplied by the user
1 parent 039db66 commit 0252379

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/GitVersionTfsTask/GitVersion.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ export class GitVersionTask {
77
execOptions: tr.IExecOptions;
88

99
preferBundledVersion: boolean;
10+
configFilePathSupplied: boolean;
1011
configFilePath: string;
1112
updateAssemblyInfo: boolean;
1213

@@ -21,6 +22,7 @@ export class GitVersionTask {
2122

2223
constructor() {
2324
this.preferBundledVersion = tl.getBoolInput('preferBundledVersion') || true;
25+
this.configFilePathSupplied = tl.filePathSupplied('configFilePath');
2426
this.configFilePath = tl.getPathInput('configFilePath');
2527
this.updateAssemblyInfo = tl.getBoolInput('updateAssemblyInfo');
2628

@@ -58,7 +60,7 @@ export class GitVersionTask {
5860
"buildserver",
5961
"/nofetch"]);
6062

61-
if (this.configFilePath) {
63+
if (this.configFilePathSupplied && this.configFilePath) {
6264
exe.arg(["/config", this.configFilePath]);
6365
}
6466

0 commit comments

Comments
 (0)