mcp-gov 1.2.3 → 1.2.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.
- package/bin/mcp-gov.js +34 -18
- package/package.json +1 -1
package/bin/mcp-gov.js
CHANGED
|
@@ -82,17 +82,25 @@ async function main() {
|
|
|
82
82
|
}
|
|
83
83
|
|
|
84
84
|
async function handleWrap() {
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
85
|
+
let path;
|
|
86
|
+
while (true) {
|
|
87
|
+
const configPath = await ask('Enter config path (e.g. ~/.claude.json): ');
|
|
88
|
+
const input = configPath.trim();
|
|
89
|
+
|
|
90
|
+
if (!input) {
|
|
91
|
+
console.log('Path required. Please try again.\n');
|
|
92
|
+
continue;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
path = input.startsWith('~') ? input.replace('~', homedir()) : input;
|
|
91
96
|
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
97
|
+
if (existsSync(path)) {
|
|
98
|
+
break;
|
|
99
|
+
}
|
|
100
|
+
console.log(`\nFile not found: ${path}`);
|
|
101
|
+
console.log('Please try again.\n');
|
|
95
102
|
}
|
|
103
|
+
rl.close();
|
|
96
104
|
|
|
97
105
|
console.log(`\nWrapping servers...\n`);
|
|
98
106
|
|
|
@@ -106,17 +114,25 @@ async function handleWrap() {
|
|
|
106
114
|
}
|
|
107
115
|
|
|
108
116
|
async function handleUnwrap() {
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
117
|
+
let path;
|
|
118
|
+
while (true) {
|
|
119
|
+
const configPath = await ask('Enter config path (e.g. ~/.claude.json): ');
|
|
120
|
+
const input = configPath.trim();
|
|
121
|
+
|
|
122
|
+
if (!input) {
|
|
123
|
+
console.log('Path required. Please try again.\n');
|
|
124
|
+
continue;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
path = input.startsWith('~') ? input.replace('~', homedir()) : input;
|
|
115
128
|
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
129
|
+
if (existsSync(path)) {
|
|
130
|
+
break;
|
|
131
|
+
}
|
|
132
|
+
console.log(`\nFile not found: ${path}`);
|
|
133
|
+
console.log('Please try again.\n');
|
|
119
134
|
}
|
|
135
|
+
rl.close();
|
|
120
136
|
|
|
121
137
|
console.log(`\nUnwrapping servers...\n`);
|
|
122
138
|
|