Skip to content

Commit 1fa540c

Browse files
authored
Merge pull request #9612 from keymanapp/chore/developer/9611-normalize-case-on-input-filenames
chore(developer): normalize case on input filenames in kmc 🎺
2 parents cb3d526 + c95b0dd commit 1fa540c

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

developer/src/kmc/src/commands/build.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,10 @@ async function build(filename: string, parentCallbacks: NodeCompilerCallbacks, o
116116
return false;
117117
}
118118

119+
// Normalize case for the filename and expand the path; this avoids false
120+
// positive case mismatches on input filenames and glommed paths
121+
filename = fs.realpathSync.native(filename);
122+
119123
let builder = null;
120124

121125
// If infile is a directory, then we treat that as a project and build it

developer/src/kmc/src/commands/buildWindowsPackageInstaller/index.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@ export async function buildWindowsPackageInstaller(infile: string, _options: any
2626
titleImageFilename: options.titleImage
2727
}
2828

29+
// Normalize case for the filename and expand the path; this avoids false
30+
// positive case mismatches on input filenames and glommed paths
31+
infile = fs.realpathSync.native(infile);
32+
2933
const callbacks: CompilerCallbacks = new NodeCompilerCallbacks({...defaultCompilerOptions, ...options});
3034
const compiler = new WindowsPackageInstallerCompiler(callbacks);
3135

0 commit comments

Comments
 (0)