loopwright 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.
Files changed (2) hide show
  1. package/README.md +12 -9
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -144,13 +144,14 @@ All worktrees of a repo share one `.loopwright/` in the main worktree (found via
144
144
 
145
145
  ## Releasing (maintainers)
146
146
 
147
- `main` only accepts pull requests, so **a release is a merged PR that bumps the `version` in `package.json`**. On every push to `main`, `.github/workflows/publish.yml` checks whether that version is already released; if not, it:
147
+ `main` only accepts pull requests, so **a release is a merged PR that bumps the `version` in `package.json`**. Releases use npm **staged publishing**: CI can stage a version but cannot make it installable, so every release needs your 2FA approval.
148
148
 
149
- 1. Runs `npm ci`, the typecheck, and the tests.
150
- 2. Publishes to npm with trusted publishing (OIDC; no npm token in the repo). A version already on npm is not re-published.
151
- 3. Creates the `vX.Y.Z` tag on the merge commit and a GitHub release with generated notes.
149
+ When CI (`ci.yml`) passes for a push to `main`, `.github/workflows/publish.yml` runs for that exact commit. If its version has no GitHub release yet, it:
152
150
 
153
- Pushes that don't change the version (and the `0.0.0` placeholder) release nothing. A failed run leaves no tag; fix the cause, then re-run it from the Actions tab ("Run workflow" on `main`).
151
+ 1. Builds and runs `npm stage publish` with trusted publishing (OIDC; no npm token in the repo). A version already live on npm is not staged again.
152
+ 2. Creates the `vX.Y.Z` tag on that commit and a GitHub release with generated notes.
153
+
154
+ CI failures, pushes that don't change the version, and the `0.0.0` placeholder release nothing. A failed run leaves no tag; fix the cause, then re-run it from the Actions tab ("Run workflow" on `main`, which first checks that CI passed for `main`'s head).
154
155
 
155
156
  **To release a new version:**
156
157
 
@@ -163,11 +164,13 @@ git push -u origin HEAD
163
164
  gh pr create --fill # merge it once CI is green
164
165
  ```
165
166
 
166
- **One-time setup** (needed once, for the first release):
167
+ Then **approve the staged version**: on npmjs.com → `loopwright` → **Staged Packages** → **Approve** (or `npm stage list loopwright` and `npm stage approve <id>`, npm ≥ 11.15). It becomes installable and `latest` only after approval. Check with `npm view loopwright versions dist-tags`.
168
+
169
+ **One-time setup:**
167
170
 
168
- 1. Trusted publishing can only be configured for a package that already exists, so the first version is published by hand from the bump branch before merging: `npm login`, then `npm publish --access public` (`prepublishOnly` builds `dist/` first). Merging the PR then sees the version on npm and only creates the tag and release.
169
- 2. On npmjs.com → `loopwright` → Settings → Trusted publishing, add GitHub Actions with repository `xuansontrinh/loopwright` and workflow `publish.yml`.
170
- 3. A trusted-publisher config that has not completed a publish expires after 48 hours, so add it when you are about to merge the next version bump. After CI has published once, disallow token-based publishing in the package settings.
171
+ 1. Trusted publishing can only be configured for a package that already exists, so the first version (0.1.0) is published by hand (`npm publish --access public`; `prepublishOnly` builds `dist/`).
172
+ 2. On npmjs.com → `loopwright` → Settings → Trusted publishing → GitHub Actions: repository `xuansontrinh/loopwright`, workflow `publish.yml`, with **Allow `npm publish`** and **Allow `npm dist-tag`** left unchecked (stage-only).
173
+ 3. Publishing access: "Require two-factor authentication and disallow tokens".
171
174
 
172
175
  ## License
173
176
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "loopwright",
3
3
  "author": "Xuan Son Trinh",
4
- "version": "0.1.0",
4
+ "version": "0.1.1",
5
5
  "description": "Agent workflow installer for Claude Code and Codex",
6
6
  "type": "module",
7
7
  "bin": {