9routerx 0.0.0-stage → 1.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.
@@ -0,0 +1,34 @@
1
+ #!/usr/bin/env node
2
+ 'use strict';
3
+ const { platform, arch } = process;
4
+ const map = {
5
+ win32: { x64: 'win32-x64', arm64: 'win32-arm64' },
6
+ linux: { x64: 'linux-x64', arm64: 'linux-arm64' },
7
+ darwin: { x64: 'darwin-x64', arm64: 'darwin-arm64' },
8
+ };
9
+ const t = (map[platform] || {})[arch];
10
+ if (!t) {
11
+ console.error('9RouterX: unsupported platform ' + platform + '/' + arch);
12
+ process.exit(1);
13
+ }
14
+ const pkg = '@yanstd888/9routerx-' + t;
15
+ const ext = platform === 'win32' ? '.exe' : '';
16
+ let bin;
17
+ try {
18
+ const root = require.resolve(pkg + '/package.json');
19
+ bin = require('path').join(require('path').dirname(root), 'bin', '9routerx' + ext);
20
+ } catch (err) {
21
+ console.error('9RouterX: the platform binary package ' + pkg + ' was not installed (' + (err.code || err.message) + ').');
22
+ console.error('Reinstall with: npm i -g 9routerx');
23
+ process.exit(1);
24
+ }
25
+ const { spawnSync } = require('child_process');
26
+ const r = spawnSync(bin, process.argv.slice(2), {
27
+ stdio: 'inherit',
28
+ env: Object.assign({}, process.env, { '9ROUTERX_NPM_INSTALL': '1' }),
29
+ });
30
+ if (r.error) {
31
+ console.error('9RouterX: failed to launch ' + bin + ' (' + r.error.message + ').');
32
+ process.exit(1);
33
+ }
34
+ process.exit(r.status === null ? 1 : r.status);
package/package.json CHANGED
@@ -1,6 +1,37 @@
1
1
  {
2
2
  "name": "9routerx",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "1.1.0",
4
+ "description": "9RouterX — 9R Next Go Generation: local AI gateway (installs the right platform binary)",
5
+ "bin": {
6
+ "9routerx": "bin/launcher.js"
7
+ },
8
+ "files": [
9
+ "bin"
10
+ ],
11
+ "optionalDependencies": {
12
+ "@yanstd888/9routerx-win32-x64": "1.1.0",
13
+ "@yanstd888/9routerx-linux-x64": "1.1.0",
14
+ "@yanstd888/9routerx-linux-arm64": "1.1.0",
15
+ "@yanstd888/9routerx-darwin-x64": "1.1.0",
16
+ "@yanstd888/9routerx-darwin-arm64": "1.1.0"
17
+ },
18
+ "license": "MIT",
19
+ "repository": {
20
+ "type": "git",
21
+ "url": "git+https://github.com/yanstd888/9routerx.git"
22
+ },
23
+ "author": "Muhammad Dian (yanstd888)",
24
+ "keywords": [
25
+ "ai",
26
+ "gateway",
27
+ "router",
28
+ "llm",
29
+ "proxy"
30
+ ],
31
+ "engines": {
32
+ "node": ">=18"
33
+ },
34
+ "publishConfig": {
35
+ "access": "public"
36
+ }
37
+ }
package/README.md DELETED
@@ -1,3 +0,0 @@
1
- # Temporary Holding Version
2
-
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.