@vectorize-io/self-driving-agents 0.0.2 → 0.0.3

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 (2) hide show
  1. package/dist/cli.js +4 -8
  2. package/package.json +1 -1
package/dist/cli.js CHANGED
@@ -67,22 +67,18 @@ async function resolveAgentDir(input, spinner) {
67
67
  // Parse GitHub reference: "name" or "org/repo/path/to/agent"
68
68
  const parts = input.split("/");
69
69
  let org, repo, subpath;
70
- if (parts.length === 1) {
71
- // Just a name → default repo
70
+ if (parts.length <= 2) {
71
+ // "name" or "name/subpath" → default repo
72
72
  org = "vectorize-io";
73
73
  repo = "self-driving-agents";
74
- subpath = parts[0];
74
+ subpath = input;
75
75
  }
76
- else if (parts.length >= 3) {
76
+ else {
77
77
  // org/repo/path...
78
78
  org = parts[0];
79
79
  repo = parts[1];
80
80
  subpath = parts.slice(2).join("/");
81
81
  }
82
- else {
83
- throw new Error(`Invalid agent reference: '${input}'\n` +
84
- ` Use: <name>, <org>/<repo>/<path>, or a local path (./dir)`);
85
- }
86
82
  spinner.start(`Fetching ${color.cyan(`${org}/${repo}/${subpath}`)} from GitHub...`);
87
83
  const tmp = join(tmpdir(), `sda-${Date.now()}`);
88
84
  mkdirSync(tmp, { recursive: true });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vectorize-io/self-driving-agents",
3
- "version": "0.0.2",
3
+ "version": "0.0.3",
4
4
  "description": "Install self-driving agents with portable memory on any harness",
5
5
  "type": "module",
6
6
  "main": "dist/cli.js",