naracli 1.0.13 → 1.0.15

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.
@@ -0,0 +1,3 @@
1
+ const _w = console.warn;
2
+ console.warn = (...a) => { if (String(a[0]).includes("bigint")) return; _w(...a); };
3
+ try { process.loadEnvFile(); } catch {}
package/bin/nara-cli.ts CHANGED
@@ -5,6 +5,10 @@
5
5
  import { Command } from "commander";
6
6
  import { registerCommands } from "../src/cli/index";
7
7
  import { loadWallet } from "../src/cli/utils/wallet";
8
+ import { createRequire } from "node:module";
9
+
10
+ const require = createRequire(import.meta.url);
11
+ const { version } = require("../package.json");
8
12
 
9
13
  // Create program
10
14
  const program = new Command();
@@ -13,7 +17,7 @@ const program = new Command();
13
17
  program
14
18
  .name("naracli")
15
19
  .description("CLI for the Nara chain (Solana-compatible)")
16
- .version("0.1.0");
20
+ .version(version);
17
21
 
18
22
  // Add global options
19
23
  program
package/dist/nara-cli.mjs CHANGED
@@ -1,6 +1,3 @@
1
- #!/usr/bin/env node
2
- try{process.loadEnvFile()}catch{}
3
-
4
1
  // bin/nara-cli.ts
5
2
  import { Command as Command8 } from "commander";
6
3
 
@@ -2629,8 +2626,11 @@ function registerCommands(program2) {
2629
2626
  }
2630
2627
 
2631
2628
  // bin/nara-cli.ts
2629
+ import { createRequire as createRequire2 } from "node:module";
2630
+ var require2 = createRequire2(import.meta.url);
2631
+ var { version } = require2("../package.json");
2632
2632
  var program = new Command8();
2633
- program.name("naracli").description("CLI for the Nara chain (Solana-compatible)").version("0.1.0");
2633
+ program.name("naracli").description("CLI for the Nara chain (Solana-compatible)").version(version);
2634
2634
  program.option("-r, --rpc-url <url>", "RPC endpoint URL").option("-w, --wallet <path>", "Path to wallet keypair JSON file").option("-j, --json", "Output in JSON format");
2635
2635
  program.command("address").description("Show wallet address").action(async () => {
2636
2636
  const opts = program.opts();
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env node
2
+ const _w=console.warn;console.warn=(...a)=>{if(String(a[0]).includes("bigint"))return;_w(...a)};
3
+ try{process.loadEnvFile()}catch{}
4
+ import("./nara-cli.mjs");
package/package.json CHANGED
@@ -1,17 +1,17 @@
1
1
  {
2
2
  "name": "naracli",
3
- "version": "1.0.13",
3
+ "version": "1.0.15",
4
4
  "description": "CLI for the Nara chain (Solana-compatible)",
5
5
  "module": "index.ts",
6
6
  "main": "index.ts",
7
7
  "type": "module",
8
8
  "private": false,
9
9
  "bin": {
10
- "naracli": "./dist/nara-cli.mjs"
10
+ "naracli": "./dist/naracli.cjs"
11
11
  },
12
12
  "scripts": {
13
- "cli": "node --env-file=.env --import tsx bin/nara-cli.ts",
14
- "build": "npx esbuild bin/nara-cli.ts --bundle --platform=node --format=esm --outfile=dist/nara-cli.mjs --packages=external --banner:js='#!/usr/bin/env node\ntry{process.loadEnvFile()}catch{}' && mkdir -p dist/zk dist/quest && cp src/cli/zk/answer_proof.wasm src/cli/zk/answer_proof_final.zkey dist/zk/ && cp src/cli/quest/nara_quest.json dist/quest/",
13
+ "cli": "node --require ./bin/env-loader.cjs --import tsx bin/nara-cli.ts",
14
+ "build": "npx esbuild bin/nara-cli.ts --bundle --platform=node --format=esm --outfile=dist/nara-cli.mjs --packages=external && mkdir -p dist/zk dist/quest && cp src/cli/zk/answer_proof.wasm src/cli/zk/answer_proof_final.zkey dist/zk/ && cp src/cli/quest/nara_quest.json dist/quest/ && printf '#!/usr/bin/env node\\nconst _w=console.warn;console.warn=(...a)=>{if(String(a[0]).includes(\"bigint\"))return;_w(...a)};\\ntry{process.loadEnvFile()}catch{}\\nimport(\"./nara-cli.mjs\");\\n' > dist/naracli.cjs",
15
15
  "prepublishOnly": "npm run build"
16
16
  },
17
17
  "files": [