mirror of
https://github.com/Azgaar/Fantasy-Map-Generator.git
synced 2026-03-22 15:17:23 +01:00
Update scripts/bump-version.js
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
parent
ff42f711f4
commit
30665ff4c5
1 changed files with 8 additions and 3 deletions
|
|
@ -231,9 +231,14 @@ function updatePublicJsDynamicImportHashes(changedFiles, newVersion, dry) {
|
|||
if (changedFiles.length === 0) {
|
||||
console.log(" public/**/*.js (no changed public/*.js files detected)");
|
||||
return;
|
||||
}
|
||||
|
||||
const changedSet = new Set(changedFiles);
|
||||
const replacement = `${quote}${relImportPath}?v=${newVersion}${quote}`;
|
||||
// Only record and apply an update if the version actually changes
|
||||
if (match === replacement) {
|
||||
return match;
|
||||
}
|
||||
if (!updatedMap[relJsFile]) updatedMap[relJsFile] = [];
|
||||
updatedMap[relJsFile].push(relImportPath);
|
||||
return replacement;
|
||||
const publicJsFiles = getAllPublicJsFiles();
|
||||
const updatedMap = {};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue