mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-16 15:30:41 +09:00
Rename sharedMods to mods on migration
The place for storing mods was changed from sharedMods to mods when mod management was implemented. Rename the old sharedMods folder to mods when the migration script is invoked.
This commit is contained in:
1 parent
adc2d9cb4d
commit
5e2221796a
1 file changed
+8
@@ -281,6 +281,14 @@ async function migrateRename(args) {
|
||||
await migrateLogsDir(path.join("logs", "cluster-prerename"), path.join("logs", "cluster"));
|
||||
}
|
||||
|
||||
if (
|
||||
await fs.pathExists("sharedMods")
|
||||
&& !await fs.pathExists("mods")
|
||||
) {
|
||||
logger.info("Moving sharedMods/ to mods/");
|
||||
await fs.rename("sharedMods", "mods");
|
||||
}
|
||||
|
||||
if (!args.dev) {
|
||||
let pkg = JSON.parse(await fs.readFile("package.json"));
|
||||
if (pkg.dependencies) {
|
||||
|
||||
Reference in new issue
Block a user