Skip to content

Commit

Permalink
Revert back to explicitly pre-staging static, though per discussions …
Browse files Browse the repository at this point in the history
…we probably want to isolate this to static/dist
  • Loading branch information
dannon committed Oct 15, 2024
1 parent 2a68691 commit d489cc1
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions client/gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -245,11 +245,10 @@ async function installDependenciesFromXML(xmlPath, pluginDir) {
);

if (installResult.status === 0) {
const packagePath = path.join(pluginDir, "node_modules", pkgName);
const defaultPath = path.join(packagePath, "static");
const alternatePath = path.join(packagePath, "dist/static");
const sourcePath = fs.existsSync(defaultPath) ? defaultPath : alternatePath;
await fs.copy(sourcePath, path.join(pluginDir, "static"));
await fs.copy(
path.join(pluginDir, "node_modules", pkgName, "static"),
path.join(pluginDir, "static")
);
console.log(`Installed package ${pkgName}@${version} in ${pluginDir}`);
} else {
console.error(`Error installing package ${pkgName}@${version} in ${pluginDir}`);
Expand Down

0 comments on commit d489cc1

Please sign in to comment.