Move config command to lib/shared_commands

Move the definition and implementation of the config command to
lib/shared_comhmands.js, this removes the need for lib config to depend
on the fs module, which is not accessible in web build.
This commit is contained in:
Hornwitser committed 2020-11-07 20:23:06 +01:00
1 parent bd1414dd1c
commit bcd1290301
5 files changed
+82 -81

No files matched your search

+2 -2
View File
@@ -1395,7 +1395,7 @@ async function startSlave() {
type: "string",
})
.command("plugin", "Manage available plugins", libSharedCommands.pluginCommand)
.command("config", "Manage Slave config", libConfig.configCommand)
.command("config", "Manage Slave config", libSharedCommands.configCommand)
.command("run", "Run slave")
.demandCommand(1, "You need to specify a command to run")
.strict()
@@ -1440,7 +1440,7 @@ async function startSlave() {
}
if (command === "config") {
await libConfig.handleConfigCommand(args, slaveConfig, args.config);
await libSharedCommands.handleConfigCommand(args, slaveConfig, args.config);
return;
}