repown 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/CHANGELOG.md CHANGED
@@ -7,6 +7,14 @@ commands. How a release is cut: [docs/RELEASING.md](docs/RELEASING.md).
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [0.1.1] - 2026-09-25
11
+
12
+ - Fixed: `repown use -` (and `accounts add -`, `accounts remove -`, `scan -`) is a
13
+ usage error again. 0.1.0 read the bare `-` as a name and pinned an account called
14
+ "-".
15
+ - Unknown commands and actions now say which `repown help` to run.
16
+ - Published from GitHub Actions through npm trusted publishing, with provenance.
17
+
10
18
  ## [0.1.0] - 2026-09-25
11
19
 
12
20
  - First release on npm: `npm install -g repown`.
@@ -23,5 +31,6 @@ commands. How a release is cut: [docs/RELEASING.md](docs/RELEASING.md).
23
31
  contract for scripts.
24
32
  - Runs on Node 20+ on Windows, macOS and Linux, with zero runtime dependencies.
25
33
 
26
- [Unreleased]: https://github.com/makubexD/repown/compare/v0.1.0...HEAD
34
+ [Unreleased]: https://github.com/makubexD/repown/compare/v0.1.1...HEAD
35
+ [0.1.1]: https://github.com/makubexD/repown/compare/v0.1.0...v0.1.1
27
36
  [0.1.0]: https://github.com/makubexD/repown/releases/tag/v0.1.0
package/README.md CHANGED
@@ -69,9 +69,9 @@ npm install -g repown
69
69
  ```
70
70
 
71
71
  To try it without installing, run `npx repown doctor`. The package has no runtime
72
- dependencies, and each version is published from CI with
72
+ dependencies. From 0.1.1 on, each version is published from CI with
73
73
  [provenance](https://docs.npmjs.com/generating-provenance-statements), so npm shows the
74
- commit and workflow that built it. Update with `npm install -g repown@latest`; a guarded
74
+ commit and workflow that built it (0.1.0 was published by hand, and has none). Update with `npm install -g repown@latest`; a guarded
75
75
  clone keeps working, because its hook calls the installed CLI
76
76
  ([ADR-003](docs/decisions/ADR-003-hook-calls-installed-cli.md)).
77
77
 
@@ -197,8 +197,8 @@ git push --follow-tags # CI publishes to npm (trusted publishing) and creates t
197
197
  ```
198
198
 
199
199
  `release:*` runs `npm version`, which refuses unless the repository is ready
200
- (`npm run release:check`), the tests and build pass, and the tarball holds only what
201
- it should (`npm run pack:check`). It then dates the changelog, commits and tags
200
+ (`npm run release:check`), the tests and build pass, and the tarball has the files it
201
+ needs and none it mustn't ship (`npm run pack:check`). It then dates the changelog, commits and tags
202
202
  `v<version>` locally. The whole routine is in [docs/RELEASING.md](docs/RELEASING.md);
203
203
  what changed in each version is in [CHANGELOG.md](CHANGELOG.md).
204
204
 
package/dist/ui/args.js CHANGED
@@ -38,7 +38,8 @@ export function parseArgs(tokens, spec) {
38
38
  let optionsEnded = false;
39
39
  for (let index = 0; index < tokens.length; index += 1) {
40
40
  const token = tokens[index];
41
- if (optionsEnded || token === '-' || !token.startsWith('-')) {
41
+ const stdinDash = token === '-' && spec.positionals.stdin === true;
42
+ if (optionsEnded || stdinDash || !token.startsWith('-')) {
42
43
  positional.push(token);
43
44
  continue;
44
45
  }
@@ -72,11 +72,11 @@ async function dispatch(program, top) {
72
72
  return runLeaf(program, { path: [name], command: entry, rest, tag: top.implicit ? program.name : name });
73
73
  const picked = resolveAction(entry, rest);
74
74
  if (!picked.ok) {
75
- reportUsageError(name, picked.error);
75
+ reportUsageError(name, picked.error + helpPointer(program, [name]));
76
76
  return 2;
77
77
  }
78
78
  const { command, action, remaining, explicit } = picked.value;
79
- if (!explicit && hasHelpFlag(remaining)) {
79
+ if (!explicit && hasHelpFlag(remaining, specFor(command).options)) {
80
80
  printHelp(program, [name], entry);
81
81
  return 0;
82
82
  }
@@ -125,7 +125,7 @@ export async function runProgram(program, argv) {
125
125
  return runHelp(program, []);
126
126
  const top = await resolveTop(program, argv);
127
127
  if (!top.ok) {
128
- reportUsageError(program.name, top.error);
128
+ reportUsageError(program.name, top.error + helpPointer(program, []));
129
129
  return 2;
130
130
  }
131
131
  return dispatch(program, top.value);
package/dist/ui/help.js CHANGED
@@ -42,7 +42,7 @@ function environmentHelp() {
42
42
  '',
43
43
  ];
44
44
  }
45
- export function renderCommandHelp(path, command, program = 'repown') {
45
+ export function renderCommandHelp(path, command, program) {
46
46
  const lines = ['', ' ' + usageFor(program, path, command), '', ' ' + command.summary, ''];
47
47
  if (optionsOf(command).length > 0)
48
48
  lines.push(...optionsHelp(command), '');
@@ -51,7 +51,7 @@ export function renderCommandHelp(path, command, program = 'repown') {
51
51
  lines.push(...examplesHelp(command.examples), '');
52
52
  return lines;
53
53
  }
54
- export function renderGroupHelp(path, group, program = 'repown') {
54
+ export function renderGroupHelp(path, group, program) {
55
55
  const lines = ['', ' ' + program + ' ' + path.join(' ') + ' <action>', '', ' Actions:'];
56
56
  for (const [name, action] of Object.entries(group.actions)) {
57
57
  const marker = name === group.defaultAction ? ' (default)' : '';
@@ -60,7 +60,7 @@ export function renderGroupHelp(path, group, program = 'repown') {
60
60
  lines.push('', ' Run `' + program + ' help ' + path.join(' ') + ' <action>` for its options.', '');
61
61
  return lines;
62
62
  }
63
- export function renderHelpFor(path, entry, program = 'repown') {
63
+ export function renderHelpFor(path, entry, program) {
64
64
  return isGroup(entry) ? renderGroupHelp(path, entry, program) : renderCommandHelp(path, entry, program);
65
65
  }
66
66
  function usageFor(program, path, command) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "repown",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "Use several git accounts on one machine: each repo owns its identity, so you move between repos with no switch command and never push the wrong one.",
5
5
  "repository": {
6
6
  "type": "git",