@zicolasjac-ai/remote-readonly-ssh 1.1.4 → 1.1.5

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/init.js +5 -5
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zicolasjac-ai/remote-readonly-ssh",
3
- "version": "1.1.4",
3
+ "version": "1.1.5",
4
4
  "description": "只读 SSH 运维 CLI 与 Agent Skill:通过 JumpServer 堡垒机白名单强制执行只读查询;附 SKILL.md 让 opencode / Claude Code / Cursor 等 AI 助手自动发现并正确调用。",
5
5
  "license": "MIT",
6
6
  "bin": {
package/src/init.js CHANGED
@@ -97,14 +97,14 @@ async function runInteractive({ input = process.stdin, output = process.stdout,
97
97
  ? rlFactory()
98
98
  : readline.createInterface({ input, output });
99
99
  try {
100
- let overwrite = "n";
100
+ let overwrite = "1";
101
101
  if (existed) {
102
- const ans = (await rl.question(`检测到已存在配置 ${dest}\n (n) 跳过配置,仅安装 skill (b) 备份后重写 (y) 直接覆盖 [n]: `)).trim().toLowerCase();
103
- overwrite = ans || "n";
102
+ const ans = (await rl.question(`检测到已存在配置 ${dest}\n (1) 跳过配置,仅安装 skill (2) 备份后重写 (3) 直接覆盖 [1]: `)).trim();
103
+ overwrite = ans || "1";
104
104
  }
105
105
 
106
- if (!existed || overwrite === "y" || overwrite === "b") {
107
- if (existed && overwrite === "b") {
106
+ if (!existed || overwrite === "3" || overwrite === "2") {
107
+ if (existed && overwrite === "2") {
108
108
  fs.copyFileSync(dest, dest + ".bak");
109
109
  }
110
110
  fs.mkdirSync(destDir, { recursive: true });