tessera-codegraph 0.0.0-stage → 1.2.1

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/tessera.js ADDED
@@ -0,0 +1,20 @@
1
+ #!/usr/bin/env node
2
+ "use strict";
3
+
4
+ const { spawnSync } = require("child_process");
5
+ const { resolveBinary } = require("../lib/resolve");
6
+
7
+ let bin;
8
+ try {
9
+ bin = resolveBinary();
10
+ } catch (error) {
11
+ console.error(`[tessera] ${error.message}`);
12
+ process.exit(1);
13
+ }
14
+
15
+ const result = spawnSync(bin, process.argv.slice(2), { stdio: "inherit" });
16
+ if (result.error) {
17
+ console.error(`[tessera] failed to launch ${bin}: ${result.error.message}`);
18
+ process.exit(1);
19
+ }
20
+ process.exit(result.status === null ? 1 : result.status);
package/lib/resolve.js ADDED
@@ -0,0 +1,43 @@
1
+ "use strict";
2
+
3
+ const PACKAGES = {
4
+ "darwin-arm64": "tessera-codegraph-darwin-arm64",
5
+ "darwin-x64": "tessera-codegraph-darwin-x64",
6
+ "linux-x64-musl": "tessera-codegraph-linux-x64-musl",
7
+ "linux-arm64-musl": "tessera-codegraph-linux-arm64-musl",
8
+ "win32-x64": "tessera-codegraph-win32-x64",
9
+ };
10
+
11
+ function currentHost() {
12
+ return { platform: process.platform, arch: process.arch };
13
+ }
14
+
15
+ // Linux always gets the static musl build: it runs on every distribution,
16
+ // including glibc versions older than the ones release runners link against.
17
+ function platformPackage(host = currentHost()) {
18
+ let key = `${host.platform}-${host.arch}`;
19
+ if (host.platform === "linux") key += "-musl";
20
+ const name = PACKAGES[key];
21
+ if (!name) {
22
+ throw new Error(
23
+ `no prebuilt tessera binary for ${host.platform}/${host.arch}; ` +
24
+ "install with `cargo install tessera-codegraph` instead"
25
+ );
26
+ }
27
+ return name;
28
+ }
29
+
30
+ function resolveBinary(host = currentHost(), resolve = require.resolve) {
31
+ const name = platformPackage(host);
32
+ const exe = host.platform === "win32" ? "tessera.exe" : "tessera";
33
+ try {
34
+ return resolve(`${name}/bin/${exe}`);
35
+ } catch (error) {
36
+ throw new Error(
37
+ `Install failed: package ${name} is missing. ` +
38
+ "Reinstall without --no-optional / --omit=optional, or use `cargo install tessera-codegraph`."
39
+ );
40
+ }
41
+ }
42
+
43
+ module.exports = { PACKAGES, platformPackage, resolveBinary };
package/package.json CHANGED
@@ -1,6 +1,42 @@
1
1
  {
2
2
  "name": "tessera-codegraph",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "1.2.1",
4
+ "description": "Deterministic edit safety for AI coding agents: blast radius before an edit, verification after it. Prebuilt tessera binary, no Rust toolchain required.",
5
+ "bin": {
6
+ "tessera": "bin/tessera.js"
7
+ },
8
+ "files": [
9
+ "bin/tessera.js",
10
+ "lib/resolve.js",
11
+ "LICENSE",
12
+ "THIRD-PARTY-NOTICES"
13
+ ],
14
+ "keywords": [
15
+ "mcp",
16
+ "mcp-server",
17
+ "ai-agents",
18
+ "claude-code",
19
+ "cursor",
20
+ "codex",
21
+ "code-graph",
22
+ "tree-sitter",
23
+ "refactoring",
24
+ "static-analysis"
25
+ ],
26
+ "homepage": "https://github.com/iamsaquib8/tessera",
27
+ "repository": {
28
+ "type": "git",
29
+ "url": "git+https://github.com/iamsaquib8/tessera.git"
30
+ },
31
+ "license": "Apache-2.0",
32
+ "engines": {
33
+ "node": ">=18"
34
+ },
35
+ "optionalDependencies": {
36
+ "tessera-codegraph-darwin-arm64": "1.2.1",
37
+ "tessera-codegraph-darwin-x64": "1.2.1",
38
+ "tessera-codegraph-linux-x64-musl": "1.2.1",
39
+ "tessera-codegraph-linux-arm64-musl": "1.2.1",
40
+ "tessera-codegraph-win32-x64": "1.2.1"
41
+ }
42
+ }