snow-flow 10.0.0 → 10.0.1-dev.362
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/README.md +24 -21
- package/bin/snow-code +5 -1
- package/package.json +2 -2
- package/script/publish-registries.ts +2 -2
- package/scripts/postinstall.cjs +9 -9
- package/src/cli/cmd/tui/component/dialog-servicenow-llm.tsx +1079 -184
- package/src/cli/cmd/tui/component/prompt/index.tsx +1 -1
- package/src/cli/cmd/tui/component/tips.tsx +30 -30
- package/src/provider/provider.ts +188 -39
- package/src/servicenow/servicenow-mcp-unified/tools/deployment/snow_artifact_manage.ts +202 -73
- package/src/servicenow/servicenow-mcp-unified/tools/platform/snow_create_script_include.ts +81 -7
package/README.md
CHANGED
|
@@ -1,7 +1,12 @@
|
|
|
1
1
|
<p align="center">
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
<pre align="center">
|
|
3
|
+
███████╗███╗ ██╗ ██████╗ ██╗ ██╗███████╗██╗ ██████╗ ██╗ ██╗
|
|
4
|
+
██╔════╝████╗ ██║██╔═══██╗██║ ██║██╔════╝██║ ██╔═══██╗██║ ██║
|
|
5
|
+
███████╗██╔██╗ ██║██║ ██║██║ █╗ ██║█████╗ ██║ ██║ ██║██║ █╗ ██║
|
|
6
|
+
╚════██║██║╚██╗██║██║ ██║██║███╗██║██╔══╝ ██║ ██║ ██║██║███╗██║
|
|
7
|
+
███████║██║ ╚████║╚██████╔╝╚███╔███╔╝██║ ███████╗╚██████╔╝╚███╔███╔╝
|
|
8
|
+
╚══════╝╚═╝ ╚═══╝ ╚═════╝ ╚══╝╚══╝ ╚═╝ ╚══════╝ ╚═════╝ ╚══╝╚══╝
|
|
9
|
+
</pre>
|
|
5
10
|
</p>
|
|
6
11
|
|
|
7
12
|
<h3 align="center">Snow-Flow</h3>
|
|
@@ -10,8 +15,7 @@
|
|
|
10
15
|
|
|
11
16
|
<p align="center">
|
|
12
17
|
<a href="https://www.npmjs.com/package/snow-flow"><img alt="npm" src="https://img.shields.io/npm/v/snow-flow?style=for-the-badge&logo=npm&logoColor=white&color=CB3837" /></a>
|
|
13
|
-
<a href="https://github.com/groeimetai/snow-flow/blob/main/LICENSE"><img alt="License" src="https://img.shields.io/github/license/groeimetai/snow-flow?style=for-the-badge&color=blue" /></a
|
|
14
|
-
<a href="https://snow-flow.dev/discord"><img alt="Discord" src="https://img.shields.io/discord/1391832426048651334?style=for-the-badge&logo=discord&logoColor=white&label=discord&color=5865F2" /></a>
|
|
18
|
+
<a href="https://github.com/groeimetai/snow-flow/blob/main/LICENSE"><img alt="License" src="https://img.shields.io/github/license/groeimetai/snow-flow?style=for-the-badge&color=blue" /></a>
|
|
15
19
|
</p>
|
|
16
20
|
|
|
17
21
|
---
|
|
@@ -31,8 +35,8 @@ bun i -g snow-flow@latest # Bun
|
|
|
31
35
|
pnpm i -g snow-flow@latest # pnpm
|
|
32
36
|
yarn global add snow-flow@latest # Yarn
|
|
33
37
|
curl -fsSL https://snow-flow.dev/install | bash # Install script
|
|
34
|
-
brew install groeimetai/tap/snow-
|
|
35
|
-
scoop install snow-
|
|
38
|
+
brew install groeimetai/tap/snow-flow # macOS / Linux
|
|
39
|
+
scoop install snow-flow # Windows
|
|
36
40
|
```
|
|
37
41
|
|
|
38
42
|
</details>
|
|
@@ -40,12 +44,12 @@ scoop install snow-code # Windows
|
|
|
40
44
|
## Quick Start
|
|
41
45
|
|
|
42
46
|
```bash
|
|
43
|
-
snow-
|
|
47
|
+
snow-flow
|
|
44
48
|
```
|
|
45
49
|
|
|
46
50
|
That's it. Snow-Flow will prompt you to configure an AI provider on first launch.
|
|
47
51
|
|
|
48
|
-
Or pre-configure in `snow-
|
|
52
|
+
Or pre-configure in `snow-flow.jsonc`:
|
|
49
53
|
|
|
50
54
|
```jsonc
|
|
51
55
|
{
|
|
@@ -178,15 +182,15 @@ Connect to your ServiceNow instance and access **200+ tools**:
|
|
|
178
182
|
## CLI
|
|
179
183
|
|
|
180
184
|
```bash
|
|
181
|
-
snow-
|
|
182
|
-
snow-
|
|
183
|
-
snow-
|
|
184
|
-
snow-
|
|
185
|
-
snow-
|
|
186
|
-
snow-
|
|
187
|
-
snow-
|
|
188
|
-
snow-
|
|
189
|
-
snow-
|
|
185
|
+
snow-flow # Start TUI
|
|
186
|
+
snow-flow serve # Headless API server (port 4096)
|
|
187
|
+
snow-flow web # Server + web interface
|
|
188
|
+
snow-flow attach <url> # Attach to remote server
|
|
189
|
+
snow-flow auth # Configure authentication
|
|
190
|
+
snow-flow models # List available models
|
|
191
|
+
snow-flow stats # Usage statistics
|
|
192
|
+
snow-flow export # Export session data
|
|
193
|
+
snow-flow pr # Pull request automation
|
|
190
194
|
```
|
|
191
195
|
|
|
192
196
|
## Configuration
|
|
@@ -196,9 +200,9 @@ Config is loaded from (in priority order):
|
|
|
196
200
|
| Priority | Source |
|
|
197
201
|
|:---------|:-------|
|
|
198
202
|
| 1 | Remote/well-known organization configs |
|
|
199
|
-
| 2 | Global config (`~/.snow-
|
|
203
|
+
| 2 | Global config (`~/.snow-flow/`) |
|
|
200
204
|
| 3 | `SNOW_FLOW_CONFIG` env variable |
|
|
201
|
-
| 4 | Project config (`snow-
|
|
205
|
+
| 4 | Project config (`snow-flow.jsonc`) |
|
|
202
206
|
| 5 | `SNOW_FLOW_CONFIG_CONTENT` inline |
|
|
203
207
|
|
|
204
208
|
<details>
|
|
@@ -253,7 +257,6 @@ Glob patterns, per-agent rulesets, and env file protection included.
|
|
|
253
257
|
|
|
254
258
|
- [Documentation](https://snow-flow.dev/docs) — Full configuration reference and guides
|
|
255
259
|
- [GitHub](https://github.com/groeimetai/snow-flow) — Source code and issues
|
|
256
|
-
- [Discord](https://snow-flow.dev/discord) — Community and support
|
|
257
260
|
- [Contributing](https://github.com/groeimetai/snow-flow/blob/main/CONTRIBUTING.md) — How to contribute
|
|
258
261
|
|
|
259
262
|
## License
|
package/bin/snow-code
CHANGED
|
@@ -43,9 +43,13 @@ let arch = archMap[os.arch()] || os.arch()
|
|
|
43
43
|
const binaryName = platform === "windows" ? "snow-code.exe" : "snow-code"
|
|
44
44
|
|
|
45
45
|
// First check: binary in our own bin directory (from postinstall download)
|
|
46
|
+
// Only run if file is >100KB (actual compiled binary), not this launcher script (~2KB)
|
|
46
47
|
const localBinary = path.join(scriptDir, binaryName)
|
|
47
48
|
if (fs.existsSync(localBinary)) {
|
|
48
|
-
|
|
49
|
+
const stats = fs.statSync(localBinary)
|
|
50
|
+
if (stats.size > 100000) {
|
|
51
|
+
run(localBinary)
|
|
52
|
+
}
|
|
49
53
|
}
|
|
50
54
|
|
|
51
55
|
// Second check: look in node_modules for platform packages
|
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/package.json",
|
|
3
|
-
"version": "10.0.
|
|
3
|
+
"version": "10.0.1-dev.362",
|
|
4
4
|
"name": "snow-flow",
|
|
5
5
|
"description": "Snow-Flow - ServiceNow Multi-Agent Development Framework powered by AI",
|
|
6
|
-
"license": "
|
|
6
|
+
"license": "Elastic-2.0",
|
|
7
7
|
"private": false,
|
|
8
8
|
"scripts": {
|
|
9
9
|
"typecheck": "tsgo --noEmit",
|
|
@@ -24,7 +24,7 @@ if (!Script.preview) {
|
|
|
24
24
|
"pkgdesc='The autonomous ServiceNow development agent.'",
|
|
25
25
|
"url='https://github.com/groeimetai/snow-flow'",
|
|
26
26
|
"arch=('aarch64' 'x86_64')",
|
|
27
|
-
"license=('
|
|
27
|
+
"license=('Elastic-2.0')",
|
|
28
28
|
"provides=('snow-code')",
|
|
29
29
|
"conflicts=('snow-code')",
|
|
30
30
|
"depends=('ripgrep')",
|
|
@@ -54,7 +54,7 @@ if (!Script.preview) {
|
|
|
54
54
|
"pkgdesc='The autonomous ServiceNow development agent.'",
|
|
55
55
|
"url='https://github.com/groeimetai/snow-flow'",
|
|
56
56
|
"arch=('aarch64' 'x86_64')",
|
|
57
|
-
"license=('
|
|
57
|
+
"license=('Elastic-2.0')",
|
|
58
58
|
"provides=('snow-code')",
|
|
59
59
|
"conflicts=('snow-code-bin')",
|
|
60
60
|
"depends=('ripgrep')",
|
package/scripts/postinstall.cjs
CHANGED
|
@@ -14,10 +14,10 @@ const archMap = { x64: 'x64', arm64: 'arm64' };
|
|
|
14
14
|
|
|
15
15
|
const platform = platformMap[os.platform()] || os.platform();
|
|
16
16
|
const arch = archMap[os.arch()] || os.arch();
|
|
17
|
-
const tarballName = 'snow-flow-
|
|
17
|
+
const tarballName = 'snow-flow-' + platform + '-' + arch + '.tar.gz';
|
|
18
18
|
|
|
19
19
|
const pkgDir = path.join(__dirname, '..');
|
|
20
|
-
const binaryName = platform === 'windows' ? '
|
|
20
|
+
const binaryName = platform === 'windows' ? 'snow-code.exe' : 'snow-code';
|
|
21
21
|
const binaryPath = path.join(pkgDir, 'bin', binaryName);
|
|
22
22
|
|
|
23
23
|
// Check if file exists AND is a real binary (not just a launcher script)
|
|
@@ -25,16 +25,16 @@ const binaryPath = path.join(pkgDir, 'bin', binaryName);
|
|
|
25
25
|
if (fs.existsSync(binaryPath)) {
|
|
26
26
|
var stats = fs.statSync(binaryPath);
|
|
27
27
|
if (stats.size > 100000) { // > 100KB means it's a real binary
|
|
28
|
-
console.log('snow-
|
|
28
|
+
console.log('snow-code: Binary already exists');
|
|
29
29
|
process.exit(0);
|
|
30
30
|
}
|
|
31
31
|
}
|
|
32
32
|
|
|
33
33
|
const releaseUrl = 'https://github.com/' + REPO + '/releases/download/v' + VERSION + '/' + tarballName;
|
|
34
|
-
console.log('snow-
|
|
34
|
+
console.log('snow-code: Downloading binary for ' + platform + '-' + arch + '...');
|
|
35
35
|
|
|
36
36
|
function followRedirects(url, callback) {
|
|
37
|
-
https.get(url, { headers: { 'User-Agent': 'snow-
|
|
37
|
+
https.get(url, { headers: { 'User-Agent': 'snow-code' } }, function(res) {
|
|
38
38
|
if (res.statusCode === 302 || res.statusCode === 301) {
|
|
39
39
|
followRedirects(res.headers.location, callback);
|
|
40
40
|
} else {
|
|
@@ -49,8 +49,8 @@ var file = fs.createWriteStream(tarPath);
|
|
|
49
49
|
|
|
50
50
|
followRedirects(releaseUrl, function(res) {
|
|
51
51
|
if (res.statusCode !== 200) {
|
|
52
|
-
console.warn('snow-
|
|
53
|
-
console.warn('snow-
|
|
52
|
+
console.warn('snow-code: Could not download binary (HTTP ' + res.statusCode + ')');
|
|
53
|
+
console.warn('snow-code: Download manually from: https://github.com/' + REPO + '/releases');
|
|
54
54
|
process.exit(0);
|
|
55
55
|
}
|
|
56
56
|
|
|
@@ -62,9 +62,9 @@ followRedirects(releaseUrl, function(res) {
|
|
|
62
62
|
if (platform !== 'windows' && fs.existsSync(binaryPath)) {
|
|
63
63
|
fs.chmodSync(binaryPath, 493);
|
|
64
64
|
}
|
|
65
|
-
console.log('snow-
|
|
65
|
+
console.log('snow-code: Binary installed successfully!');
|
|
66
66
|
} catch (e) {
|
|
67
|
-
console.warn('snow-
|
|
67
|
+
console.warn('snow-code: Could not extract binary');
|
|
68
68
|
}
|
|
69
69
|
try { fs.rmSync(tmpDir, { recursive: true }); } catch (e) {}
|
|
70
70
|
});
|