@skylandnpm/octopus-proxy 0.1.5 → 0.1.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.js +2 -1
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -288,7 +288,7 @@ async function installService(opts) {
|
|
|
288
288
|
await systemdInstall();
|
|
289
289
|
} else await systemdStart();
|
|
290
290
|
}
|
|
291
|
-
return { serviceFile: path, changed, nodePath: def.nodePath, warning };
|
|
291
|
+
return { serviceFile: path, changed, alreadyInstalled: existing !== null, nodePath: def.nodePath, warning };
|
|
292
292
|
}
|
|
293
293
|
async function uninstallService() {
|
|
294
294
|
const path = serviceFilePath();
|
|
@@ -806,6 +806,7 @@ try {
|
|
|
806
806
|
case "install": {
|
|
807
807
|
const outcome = await installService({ configPath, nodePath: flags["--node-path"], force: flags["--force"] === "true" });
|
|
808
808
|
console.log(outcome.changed ? `\u5DF2\u5B89\u88C5\u5E76\u542F\u52A8\u670D\u52A1\uFF1A${outcome.serviceFile}` : `\u670D\u52A1\u5B9A\u4E49\u4E0E\u914D\u7F6E\u4E00\u81F4\uFF0C\u5DF2\u786E\u4FDD\u8FD0\u884C\uFF1A${outcome.serviceFile}`);
|
|
809
|
+
if (outcome.alreadyInstalled && flags["--force"] !== "true") console.log("\u670D\u52A1\u5DF2\u5B89\u88C5\uFF1B\u5982\u9700\u5F3A\u5236\u91CD\u5199\u670D\u52A1\u5B9A\u4E49\u5E76\u91CD\u542F\uFF0C\u8FD0\u884C octopus-proxy install --force\uFF08\u4F7F\u7528\u81EA\u5B9A\u4E49\u914D\u7F6E\u65F6\u8BF7\u5E26\u4E0A\u76F8\u540C\u7684 --config\uFF09");
|
|
809
810
|
console.log(`node\uFF1A${outcome.nodePath}`);
|
|
810
811
|
if (outcome.warning) console.log(`\u6CE8\u610F\uFF1A${outcome.warning}`);
|
|
811
812
|
console.log(`\u65E5\u5FD7\uFF1A${logLocationHint()}\uFF08octopus-proxy logs \u67E5\u770B\uFF09`);
|