not-ace-tool-rs 0.1.0

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 (3) hide show
  1. package/README.md +79 -0
  2. package/package.json +53 -0
  3. package/run.js +75 -0
package/README.md ADDED
@@ -0,0 +1,79 @@
1
+ # not-ace-tool-rs
2
+
3
+ > **Vendored Not ACE client:** This npm package is for the Not ACE fork vendored in the ACE workspace. The published package, release assets, and installed binary use `not-ace-tool-rs` names. Historical upstream links may still mention `ace-tool-rs` when clearly identified as upstream background.
4
+
5
+ MCP server for codebase indexing, semantic search, and prompt enhancement.
6
+
7
+ ## Installation
8
+
9
+ ```bash
10
+ # Install globally
11
+ npm install -g not-ace-tool-rs
12
+
13
+ # Or run directly with npx
14
+ npx not-ace-tool-rs --help
15
+ ```
16
+
17
+ ## How It Works
18
+
19
+ This package uses platform-specific optional dependencies to provide pre-built binaries. When you install `not-ace-tool-rs`, npm automatically downloads the correct binary for your platform.
20
+
21
+ ### Supported Platforms
22
+
23
+ | Platform | Architecture | Package |
24
+ |----------|--------------|---------|
25
+ | macOS | x64, ARM64 | `@not-ace-tool-rs/darwin-universal` |
26
+ | Linux | x64 | `@not-ace-tool-rs/linux-x64` |
27
+ | Linux | ARM64 | `@not-ace-tool-rs/linux-arm64` |
28
+ | Windows | x64 | `@not-ace-tool-rs/win32-x64` |
29
+ | Windows | ARM64 | `@not-ace-tool-rs/win32-arm64` |
30
+
31
+ ## Usage
32
+
33
+ ```bash
34
+ not-ace-tool-rs --base-url <API_URL> --token <AUTH_TOKEN>
35
+ ```
36
+
37
+ ## Troubleshooting
38
+
39
+ ### Binary not found
40
+
41
+ If the platform-specific package failed to install, you can install it manually:
42
+
43
+ ```bash
44
+ # For Linux x64
45
+ npm install @not-ace-tool-rs/linux-x64
46
+
47
+ # For macOS
48
+ npm install @not-ace-tool-rs/darwin-universal
49
+
50
+ # For Windows x64
51
+ npm install @not-ace-tool-rs/win32-x64
52
+ ```
53
+
54
+ ### Alternative installation
55
+
56
+ If you have Rust installed, you can build from source:
57
+
58
+ ```bash
59
+ cargo install not-ace-tool-rs
60
+ ```
61
+
62
+ ## License
63
+
64
+ GPL-3.0-only
65
+
66
+ For commercial use, please contact missdeer@gmail.com for licensing options.
67
+
68
+ ## Verifying Downloads
69
+
70
+ Each GitHub release includes a `SHA256SUMS` file for integrity verification:
71
+
72
+ ```bash
73
+ # Download the binary and checksum file
74
+ curl -LO https://github.com/linze0721/notace-tool-rs/releases/latest/download/not-ace-tool-rs_Linux_x86_64.tar.gz
75
+ curl -LO https://github.com/linze0721/notace-tool-rs/releases/latest/download/SHA256SUMS
76
+
77
+ # Verify the checksum
78
+ sha256sum -c SHA256SUMS --ignore-missing
79
+ ```
package/package.json ADDED
@@ -0,0 +1,53 @@
1
+ {
2
+ "name": "not-ace-tool-rs",
3
+ "version": "0.1.0",
4
+ "description": "MCP server for codebase indexing, semantic search, and prompt enhancement",
5
+ "publishConfig": {
6
+ "access": "public"
7
+ },
8
+ "repository": {
9
+ "type": "git",
10
+ "url": "git+https://github.com/linze0721/notace-tool-rs.git"
11
+ },
12
+ "author": "missdeer",
13
+ "license": "GPL-3.0-only OR LicenseRef-Commercial",
14
+ "bugs": {
15
+ "url": "https://github.com/linze0721/notace-tool-rs/issues"
16
+ },
17
+ "homepage": "https://github.com/linze0721/notace-tool-rs#readme",
18
+ "keywords": [
19
+ "mcp",
20
+ "codebase",
21
+ "indexing",
22
+ "semantic-search",
23
+ "prompt-enhancement",
24
+ "rust",
25
+ "cli"
26
+ ],
27
+ "bin": {
28
+ "not-ace-tool-rs": "run.js"
29
+ },
30
+ "files": [
31
+ "run.js",
32
+ "README.md"
33
+ ],
34
+ "engines": {
35
+ "node": ">=14.14.0"
36
+ },
37
+ "os": [
38
+ "darwin",
39
+ "linux",
40
+ "win32"
41
+ ],
42
+ "cpu": [
43
+ "x64",
44
+ "arm64"
45
+ ],
46
+ "optionalDependencies": {
47
+ "@not-ace-tool-rs/darwin-universal": "0.1.0",
48
+ "@not-ace-tool-rs/linux-x64": "0.1.0",
49
+ "@not-ace-tool-rs/linux-arm64": "0.1.0",
50
+ "@not-ace-tool-rs/win32-x64": "0.1.0",
51
+ "@not-ace-tool-rs/win32-arm64": "0.1.0"
52
+ }
53
+ }
package/run.js ADDED
@@ -0,0 +1,75 @@
1
+ #!/usr/bin/env node
2
+
3
+ const { spawn } = require("child_process");
4
+ const path = require("path");
5
+ const os = require("os");
6
+
7
+ const PLATFORMS = {
8
+ "darwin-x64": "@not-ace-tool-rs/darwin-universal",
9
+ "darwin-arm64": "@not-ace-tool-rs/darwin-universal",
10
+ "linux-x64": "@not-ace-tool-rs/linux-x64",
11
+ "linux-arm64": "@not-ace-tool-rs/linux-arm64",
12
+ "win32-x64": "@not-ace-tool-rs/win32-x64",
13
+ "win32-arm64": "@not-ace-tool-rs/win32-arm64",
14
+ };
15
+
16
+ function getBinaryPath() {
17
+ const platformKey = `${process.platform}-${process.arch}`;
18
+ const pkgName = PLATFORMS[platformKey];
19
+
20
+ if (!pkgName) {
21
+ console.error(`Unsupported platform: ${process.platform}-${process.arch}`);
22
+ console.error("Supported platforms: " + Object.keys(PLATFORMS).join(", "));
23
+ process.exit(1);
24
+ }
25
+
26
+ try {
27
+ const pkgPath = require.resolve(`${pkgName}/package.json`);
28
+ const binName = process.platform === "win32" ? "not-ace-tool-rs.exe" : "not-ace-tool-rs";
29
+ return path.join(path.dirname(pkgPath), "bin", binName);
30
+ } catch (e) {
31
+ console.error(`Failed to find platform package: ${pkgName}`);
32
+ console.error("This may happen if npm failed to install the optional dependency.");
33
+ console.error("");
34
+ console.error("Try reinstalling:");
35
+ console.error(" npm install not-ace-tool-rs");
36
+ console.error("");
37
+ console.error("Or install the platform package directly:");
38
+ console.error(` npm install ${pkgName}`);
39
+ process.exit(1);
40
+ }
41
+ }
42
+
43
+ function run() {
44
+ const binaryPath = getBinaryPath();
45
+ const args = process.argv.slice(2);
46
+
47
+ const child = spawn(binaryPath, args, {
48
+ stdio: "inherit",
49
+ env: process.env,
50
+ });
51
+
52
+ // Forward signals to child process
53
+ const signals = ["SIGINT", "SIGTERM", "SIGHUP"];
54
+ signals.forEach((signal) => {
55
+ process.on(signal, () => {
56
+ if (!child.killed) {
57
+ child.kill(signal);
58
+ }
59
+ });
60
+ });
61
+
62
+ child.on("error", (error) => {
63
+ console.error(`Failed to start not-ace-tool-rs: ${error.message}`);
64
+ process.exit(1);
65
+ });
66
+
67
+ child.on("exit", (code, signal) => {
68
+ if (signal) {
69
+ process.exit(128 + (os.constants.signals[signal] || 0));
70
+ }
71
+ process.exit(code ?? 0);
72
+ });
73
+ }
74
+
75
+ run();