Skip to content

Commit 71a7c8b

Browse files
committed
chore(reviewer): release 0.3.2
- remove local npm publishing targets - reserve established package releases for the OIDC workflow
1 parent 0c42364 commit 71a7c8b

8 files changed

Lines changed: 18 additions & 92 deletions

File tree

‎Makefile‎

Lines changed: 2 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ PACKAGES := $(patsubst packages/%/Makefile,%,$(wildcard packages/*/Makefile))
88
# The per-package targets are deliberately not .PHONY: make skips the implicit
99
# rule search for phony targets, which would leave the pattern rules unmatched.
1010
# No file is ever named after them, so they always run.
11-
.PHONY: install test test-release test-load check-publish-auth check-publish publish
11+
.PHONY: install test test-release test-load check-publish
1212

1313
install:
1414
$(BUN) install
@@ -24,41 +24,12 @@ test-load: $(PACKAGES:%=test-load-%)
2424
test-load-%:
2525
$(MAKE) -C packages/$* test-load OPENCODE="$(OPENCODE)"
2626

27-
check-publish-auth:
28-
@if ! $(NPM) whoami >/dev/null 2>&1; then \
29-
echo "npm authentication is missing or expired; starting login..."; \
30-
$(NPM) login || exit $$?; \
31-
fi
32-
@identity="$$( $(NPM) whoami 2>/dev/null )" || { \
33-
echo "Cannot publish: npm authentication still failed after login." >&2; \
34-
exit 1; \
35-
}; \
36-
echo "npm authenticated as $$identity"
37-
38-
# The registry rejects a version it already has, so a release that only bumps
39-
# one package publishes that one alone: make publish-reviewer. Publishing every
40-
# package remains available for a release that bumps all of them. Check every
41-
# version before publishing any package to avoid a partial release.
27+
# Check which workspace versions are not yet present in the npm registry.
4228
check-publish:
4329
@for package in $(PACKAGES); do \
4430
$(NODE) scripts/check-publish-version.mjs packages/$$package "$(NPM)" --aggregate; status=$$?; \
4531
if [ $$status -ne 0 ] && [ $$status -ne 3 ]; then exit $$status; fi; \
4632
done
4733

48-
publish: check-publish-auth test test-load
49-
@candidates=""; \
50-
for package in $(PACKAGES); do \
51-
$(NODE) scripts/check-publish-version.mjs packages/$$package "$(NPM)" --aggregate; status=$$?; \
52-
if [ $$status -eq 0 ]; then candidates="$$candidates $$package"; \
53-
elif [ $$status -ne 3 ]; then exit $$status; fi; \
54-
done; \
55-
if [ -z "$$candidates" ]; then echo "No unpublished package versions to publish."; exit 0; fi; \
56-
for package in $$candidates; do \
57-
$(MAKE) -C packages/$$package publish || exit $$?; \
58-
done
59-
6034
check-publish-%:
6135
$(NODE) scripts/check-publish-version.mjs packages/$* "$(NPM)"
62-
63-
publish-%: check-publish-auth check-publish-% test test-load-%
64-
$(MAKE) -C packages/$* publish

‎README.md‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,4 +62,5 @@ directories.
6262
Maintainers release packages by creating package-specific Git tags. GitHub Actions tests and packs
6363
the tagged source, then publishes through npm Trusted Publishing with provenance and no stored npm
6464
token. See [RELEASING.md](RELEASING.md) for the one-time npm and GitHub setup and the release steps.
65-
The local `make publish` targets remain available for exceptional manual recovery.
65+
The repository intentionally provides no local publish target; established packages are released
66+
only through the GitHub workflow.

‎RELEASING.md‎

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,10 @@ does not block Trusted Publishing because it uses short-lived OIDC credentials r
3737
traditional tokens.
3838

3939
A newly created npm package has no npm settings page yet. Publish its first version manually with
40-
`make publish-<package>`, then add its Trusted Publisher entry before releasing its next version by
41-
tag. Trusted Publisher setup is per package, not per npm scope. This bootstrap release is the only
42-
case that should require a traditional interactive npm login.
40+
`npm publish ./packages/<package> --access public`, then add its Trusted Publisher entry before
41+
releasing its next version by tag. Trusted Publisher setup is per package, not per npm scope. This
42+
bootstrap release is the only case that should require a traditional interactive npm login. The
43+
repository intentionally provides no Makefile target for publishing established packages.
4344

4445
### New package checklist
4546

@@ -54,17 +55,18 @@ scope or another package.
5455
- `repository.directory` set to `packages/<package>`.
5556
- [ ] Add the package's tests and `Makefile`, including `test` and `test-load` targets.
5657
- [ ] Run `bun install --force`, `make test`, and `make test-load`, then merge the package to `main`.
57-
- [ ] Publish the initial version interactively with `make publish-<package>`. Do not create a
58-
release tag for this already-published version.
58+
- [ ] Publish the initial version interactively with
59+
`npm publish ./packages/<package> --access public`. Do not create a release tag for this
60+
already-published version.
5961
- [ ] On that package's npm **Settings** page, add the GitHub Actions Trusted Publisher using the
6062
exact values in the table above, including direct `npm publish` permission.
6163
- [ ] Add `refs/tags/<package>-v*` to the GitHub release-tag ruleset.
6264
- [ ] Publish the next real version through a GitHub release tag and verify that npm shows
6365
provenance for the expected commit and workflow.
6466
- [ ] Set npm **Publishing access** to **Require two-factor authentication and disallow bypass 2FA
6567
tokens (recommended)**.
66-
- [ ] Revoke any bootstrap or automation token that is no longer needed. Interactive account login
67-
remains available for emergency manual publishing and requires 2FA.
68+
- [ ] Revoke any bootstrap or automation token that is no longer needed. Publish all subsequent
69+
versions through the GitHub workflow.
6870

6971
### Protect release tags
7072

‎bun.lock‎

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎packages/commands/Makefile‎

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,8 @@
11
BUN ?= bun
2-
NPM ?= npm
3-
4-
.PHONY: test test-load check-publish-auth publish
2+
.PHONY: test test-load
53

64
test:
75
$(BUN) run test
86

97
test-load:
108
./scripts/load-check.sh
11-
12-
check-publish-auth:
13-
@if ! $(NPM) whoami >/dev/null 2>&1; then \
14-
echo "npm authentication is missing or expired; starting login..."; \
15-
$(NPM) login || exit $$?; \
16-
fi
17-
@$(NPM) whoami >/dev/null 2>&1 || { \
18-
echo "Cannot publish: npm authentication still failed after login." >&2; \
19-
exit 1; \
20-
}
21-
22-
# Prompts for an npm one-time password unless a bypass-2FA token is configured.
23-
publish: check-publish-auth
24-
$(NPM) publish --access public

‎packages/reviewer/Makefile‎

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
BUN ?= bun
2-
NPM ?= npm
3-
4-
.PHONY: install test test-load test-security check-publish-auth publish
2+
.PHONY: install test test-load test-security
53

64
install:
75
$(BUN) install
@@ -15,17 +13,3 @@ test-load:
1513

1614
test-security:
1715
REVIEWER_LIVE=1 $(BUN) test test/reviewer.test.ts --test-name-pattern 'live classifier'
18-
19-
check-publish-auth:
20-
@if ! $(NPM) whoami >/dev/null 2>&1; then \
21-
echo "npm authentication is missing or expired; starting login..."; \
22-
$(NPM) login || exit $$?; \
23-
fi
24-
@$(NPM) whoami >/dev/null 2>&1 || { \
25-
echo "Cannot publish: npm authentication still failed after login." >&2; \
26-
exit 1; \
27-
}
28-
29-
# Prompts for an npm one-time password unless a bypass-2FA token is configured.
30-
publish: check-publish-auth
31-
$(NPM) publish --access public

‎packages/reviewer/package.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@joonix/opencode-reviewer",
3-
"version": "0.3.1",
3+
"version": "0.3.2",
44
"type": "module",
55
"license": "MIT",
66
"description": "Reviews OpenCode V2 ask permissions with an LLM before a prompt is shown",

‎packages/subagent-model/Makefile‎

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,8 @@
11
BUN ?= bun
2-
NPM ?= npm
3-
4-
.PHONY: test test-load check-publish-auth publish
2+
.PHONY: test test-load
53

64
test:
75
$(BUN) run test
86

97
test-load:
108
./scripts/load-check.sh
11-
12-
check-publish-auth:
13-
@if ! $(NPM) whoami >/dev/null 2>&1; then \
14-
echo "npm authentication is missing or expired; starting login..."; \
15-
$(NPM) login || exit $$?; \
16-
fi
17-
@$(NPM) whoami >/dev/null 2>&1 || { \
18-
echo "Cannot publish: npm authentication still failed after login." >&2; \
19-
exit 1; \
20-
}
21-
22-
# Prompts for an npm one-time password unless a bypass-2FA token is configured.
23-
publish: check-publish-auth
24-
$(NPM) publish --access public

0 commit comments

Comments
 (0)