teamshift 0.1.0 → 0.1.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/README.md CHANGED
@@ -60,6 +60,5 @@ agent, with no second CLI to learn. Both install commands are in the portal unde
60
60
 
61
61
  ## Releasing
62
62
 
63
- This package is `private: true` so a workspace-wide publish cannot push it by
64
- accident. Releasing is deliberate: set `private: false`, `pnpm build`, then
65
- `npm publish`.
63
+ Published on npm as `teamshift`. To release: bump `version`, `pnpm build`, run
64
+ the package tests, then `npm publish --access public` from this directory.
package/dist/bin.js ADDED
@@ -0,0 +1,9 @@
1
+ #!/usr/bin/env node
2
+ // The bin entrypoint runs main() unconditionally. Detecting "was I executed
3
+ // directly?" from argv[1] is exactly the 0.1.0 release bug: npm invokes a bin
4
+ // through node_modules/.bin/<command> — a symlink named after the COMMAND — so
5
+ // any filename-based guard fails and the CLI exits silently. Library consumers
6
+ // import from index.ts / cli.ts, which must never self-execute; only this file
7
+ // may have side effects on import.
8
+ import { main } from './cli.js';
9
+ void main();
package/dist/cli.js CHANGED
@@ -1,4 +1,3 @@
1
- #!/usr/bin/env node
2
1
  import { createInterface } from 'node:readline/promises';
3
2
  import { PaymentRequiredError, TeamShiftClient } from './api.js';
4
3
  import { DEFAULT_API_URL, loadCredentials, maskKey, saveCredentials } from './config.js';
@@ -204,6 +203,3 @@ export async function main(argv = process.argv.slice(2)) {
204
203
  process.exit(1);
205
204
  }
206
205
  }
207
- const invokedDirectly = process.argv[1]?.endsWith('cli.js') || process.argv[1]?.endsWith('cli.ts');
208
- if (invokedDirectly)
209
- void main();
package/package.json CHANGED
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "name": "teamshift",
3
3
  "private": false,
4
- "version": "0.1.0",
5
- "description": "Run TeamShift agent teams from your terminal. Metered by usage no model key of your own required.",
4
+ "version": "0.1.1",
5
+ "description": "Run TeamShift agent teams from your terminal. Metered by usage \u2014 no model key of your own required.",
6
6
  "type": "module",
7
7
  "bin": {
8
- "teamshift": "dist/cli.js"
8
+ "teamshift": "dist/bin.js"
9
9
  },
10
10
  "main": "src/index.ts",
11
11
  "types": "src/index.ts",