clay-server 2.20.1-beta.2 → 2.20.1-beta.3
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/bin/cli.js +11 -8
- package/package.json +1 -1
package/bin/cli.js
CHANGED
|
@@ -1998,6 +1998,7 @@ function showMainMenu(config, ip, setupCode) {
|
|
|
1998
1998
|
parts.push(a.reset + a.yellow + a.bold + totalAwaiting + a.reset + a.yellow + " awaiting" + a.reset + a.dim);
|
|
1999
1999
|
}
|
|
2000
2000
|
log(" " + a.dim + parts.join(a.reset + a.dim + " · ") + a.reset);
|
|
2001
|
+
log(" " + a.dim + "~/.clay → " + path.join(REAL_HOME, ".clay") + a.reset);
|
|
2001
2002
|
log(" Press " + a.bold + "o" + a.reset + " to open in browser");
|
|
2002
2003
|
log("");
|
|
2003
2004
|
|
|
@@ -2374,8 +2375,7 @@ function showSettingsMenu(config, ip) {
|
|
|
2374
2375
|
} else {
|
|
2375
2376
|
items.push({ label: "Enable multi-user mode", value: "multi_user" });
|
|
2376
2377
|
}
|
|
2377
|
-
|
|
2378
|
-
if (muEnabled && pendingSetupCode) {
|
|
2378
|
+
if (muEnabled) {
|
|
2379
2379
|
items.push({ label: "Show setup code", value: "show_setup_code" });
|
|
2380
2380
|
}
|
|
2381
2381
|
if (muEnabled && hasAdmin()) {
|
|
@@ -2688,17 +2688,20 @@ function showSettingsMenu(config, ip) {
|
|
|
2688
2688
|
break;
|
|
2689
2689
|
|
|
2690
2690
|
case "show_setup_code":
|
|
2691
|
+
// getSetupCode() auto-generates if multi-user is on and no code exists
|
|
2691
2692
|
var currentCode = getSetupCode();
|
|
2693
|
+
log(sym.bar);
|
|
2692
2694
|
if (currentCode) {
|
|
2693
|
-
log(sym.bar);
|
|
2694
2695
|
log(sym.bar + " " + a.yellow + sym.warn + " Setup code: " + a.bold + currentCode + a.reset);
|
|
2695
|
-
|
|
2696
|
-
|
|
2696
|
+
if (hasAdmin()) {
|
|
2697
|
+
log(sym.bar + " " + a.dim + "Admin account exists. This code is for adding the next admin." + a.reset);
|
|
2698
|
+
} else {
|
|
2699
|
+
log(sym.bar + " " + a.dim + "Enter this code in the browser to create the admin account." + a.reset);
|
|
2700
|
+
}
|
|
2697
2701
|
} else {
|
|
2698
|
-
log(sym.bar);
|
|
2699
|
-
log(sym.bar + " " + a.dim + "No pending setup code (admin already exists)." + a.reset);
|
|
2700
|
-
log(sym.bar);
|
|
2702
|
+
log(sym.bar + " " + a.dim + "Multi-user mode is not enabled." + a.reset);
|
|
2701
2703
|
}
|
|
2704
|
+
log(sym.bar);
|
|
2702
2705
|
promptSelect("Back?", [{ label: "Back", value: "back" }], function () {
|
|
2703
2706
|
showSettingsMenu(config, ip);
|
|
2704
2707
|
});
|