Skip to content

Commit a8d8ca8

Browse files
committed
Add a comment for .npmrc lines that trimmed got trimmed due to a missing environment variable
1 parent a8686d5 commit a8d8ca8

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

apps/rush-lib/src/scripts/install-run.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,9 @@ function syncNpmrc(sourceNpmrcFolder: string, targetNpmrcFolder: string): void {
215215
}
216216
}
217217

218-
if (!lineShouldBeTrimmed) {
218+
if (lineShouldBeTrimmed) {
219+
resultLines.push('; MISSING ENVIRONMENT VARIABLE: ' + line);
220+
} else {
219221
resultLines.push(line);
220222
}
221223
}

apps/rush-lib/src/utilities/Utilities.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -490,7 +490,9 @@ export class Utilities {
490490
}
491491
}
492492

493-
if (!lineShouldBeTrimmed) {
493+
if (lineShouldBeTrimmed) {
494+
resultLines.push('; MISSING ENVIRONMENT VARIABLE: ' + line);
495+
} else {
494496
resultLines.push(line);
495497
}
496498
}

0 commit comments

Comments
 (0)