@unbrained/pm-cli 2026.5.4 → 2026.5.5
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 +15 -0
- package/README.md +2 -0
- package/dist/cli/commands/config.js +2 -2
- package/dist/cli/commands/config.js.map +1 -1
- package/dist/core/item/item-format.js +24 -1
- package/dist/core/item/item-format.js.map +1 -1
- package/dist/core/store/item-format-migration.js +35 -23
- package/dist/core/store/item-format-migration.js.map +1 -1
- package/docs/QUICKSTART.md +8 -0
- package/docs/RELEASING.md +9 -4
- package/package.json +1 -1
- package/scripts/install.ps1 +12 -1
- package/scripts/install.sh +17 -1
package/docs/RELEASING.md
CHANGED
|
@@ -33,8 +33,8 @@ pnpm version:check
|
|
|
33
33
|
|
|
34
34
|
## One-Time Setup
|
|
35
35
|
|
|
36
|
-
-
|
|
37
|
-
- Add `SENTRY_AUTH_TOKEN` as an optional GitHub Environment or repository secret when Sentry release creation and sourcemap upload should run. The release workflow skips
|
|
36
|
+
- Prefer npm Trusted Publishing for `.github/workflows/release.yml` so GitHub-hosted release jobs can publish with short-lived OIDC credentials. Keep `id-token: write`, `npm publish --access public --provenance`, and the package repository URL aligned with npm's Trusted Publisher configuration. If Trusted Publishing is not configured yet, add `NPM_TOKEN` as a GitHub Environment or repository secret as the fallback publisher credential.
|
|
37
|
+
- Add `SENTRY_AUTH_TOKEN` as an optional GitHub Environment or repository secret when Sentry release creation and sourcemap upload should run. Add `SENTRY_PERSONAL_ADMIN_TOKEN` only when the automated Sentry issue-threshold gate needs broader issue-read access than the CI token. The release workflow skips Sentry upload cleanly when `SENTRY_AUTH_TOKEN` is absent; the auto-release workflow skips the external Sentry gate only when no Sentry token is configured and `--telemetry-mode off` is selected.
|
|
38
38
|
- Keep any `release` environment compatible with free GitHub features. This repository is public, so environment secrets and tag/branch deployment rules are compatible with the free GitHub path; do not add paid-only release gates.
|
|
39
39
|
- Ensure `GITHUB_TOKEN` has `contents: write` for GitHub Release creation.
|
|
40
40
|
- Keep `package.json` repository, homepage, and bugs URLs aligned with `https://github.com/unbraind/pm-cli`.
|
|
@@ -47,9 +47,11 @@ pnpm version:check
|
|
|
47
47
|
Policy:
|
|
48
48
|
|
|
49
49
|
- release only when commits exist after the latest release tag
|
|
50
|
+
- ignore `.agents/pm`-only tracker commits for publish eligibility so post-release evidence and closure updates do not create a package release by themselves
|
|
50
51
|
- release at most once per UTC day by default
|
|
51
52
|
- same-day follow-up release (`YYYY.M.D-N`) is manual-only via `allow_same_day_release=true`
|
|
52
53
|
- release preparation must pass all quality and compatibility gates before commit+tag push
|
|
54
|
+
- external Sentry checks run when a Sentry token is configured; local maintainers can make Sentry and private telemetry mandatory with `--telemetry-mode required`
|
|
53
55
|
|
|
54
56
|
Pipeline entrypoint:
|
|
55
57
|
|
|
@@ -82,6 +84,7 @@ Minimum coverage:
|
|
|
82
84
|
- parent and dependency links
|
|
83
85
|
- comments, notes, learnings, body, reminders, events
|
|
84
86
|
- linked files, docs, and tests
|
|
87
|
+
- json_markdown items with external YAML wrappers before JSON front matter
|
|
85
88
|
- closed issue metadata and history drift checks
|
|
86
89
|
- current-build write mutation and item-count preservation
|
|
87
90
|
|
|
@@ -141,13 +144,15 @@ gh run watch <run-id> --exit-status
|
|
|
141
144
|
|
|
142
145
|
```bash
|
|
143
146
|
npm view @unbrained/pm-cli@<version> version dist.integrity dist.unpackedSize --json
|
|
144
|
-
npx --yes @unbrained/pm-cli@<version> --version
|
|
145
|
-
bunx @unbrained/pm-cli@<version> --version
|
|
147
|
+
npx --yes --package @unbrained/pm-cli@<version> -- pm --version
|
|
148
|
+
bunx --bun @unbrained/pm-cli@<version> pm --version
|
|
146
149
|
gh release view v<version> --json tagName,name,isDraft,isPrerelease,url
|
|
147
150
|
```
|
|
148
151
|
|
|
149
152
|
The executable remains `pm` even though the npm package is scoped.
|
|
150
153
|
|
|
154
|
+
Use the npm registry package for maintainer global updates. Do not use `npm install -g https://github.com/unbraind/pm-cli.git` as the normal update path; npm can leave a stale shim while replacing git-sourced global installs. If a workstation is already in that state, run `bash scripts/install.sh --repair` or `npm uninstall -g @unbrained/pm-cli && npm install -g @unbrained/pm-cli@latest`.
|
|
155
|
+
|
|
151
156
|
## Failure Handling
|
|
152
157
|
|
|
153
158
|
- If local gates fail, fix and rerun before tagging.
|
package/package.json
CHANGED
package/scripts/install.ps1
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
param(
|
|
2
2
|
[string]$Version = "latest",
|
|
3
3
|
[string]$Prefix = "",
|
|
4
|
-
[string]$PackageName = ""
|
|
4
|
+
[string]$PackageName = "",
|
|
5
|
+
[switch]$Repair
|
|
5
6
|
)
|
|
6
7
|
|
|
7
8
|
Set-StrictMode -Version Latest
|
|
@@ -62,6 +63,16 @@ if (Use-LiteralInstallSpec $PackageName) {
|
|
|
62
63
|
} else {
|
|
63
64
|
$installSpec = "$PackageName@$Version"
|
|
64
65
|
}
|
|
66
|
+
|
|
67
|
+
if ($Repair) {
|
|
68
|
+
Write-Host "Repairing existing global pm install..."
|
|
69
|
+
$repairArgs = @("uninstall", "-g", "@unbrained/pm-cli")
|
|
70
|
+
if ($Prefix -ne "") {
|
|
71
|
+
$repairArgs += @("--prefix", $Prefix)
|
|
72
|
+
}
|
|
73
|
+
& npm @repairArgs *> $null
|
|
74
|
+
}
|
|
75
|
+
|
|
65
76
|
Write-Host "Installing or updating $installSpec..."
|
|
66
77
|
# --force keeps repeated installer runs idempotent when pm shim already exists.
|
|
67
78
|
$npmArgs = @("install", "-g", "--force", $installSpec)
|
package/scripts/install.sh
CHANGED
|
@@ -4,17 +4,19 @@ set -euo pipefail
|
|
|
4
4
|
PACKAGE_NAME="${PM_CLI_PACKAGE:-@unbrained/pm-cli}"
|
|
5
5
|
TARGET_VERSION="latest"
|
|
6
6
|
PREFIX=""
|
|
7
|
+
REPAIR="false"
|
|
7
8
|
|
|
8
9
|
usage() {
|
|
9
10
|
cat <<'EOF'
|
|
10
11
|
Install or update @unbrained/pm-cli globally via npm.
|
|
11
12
|
|
|
12
13
|
Usage:
|
|
13
|
-
bash scripts/install.sh [--version <tag>] [--prefix <dir>]
|
|
14
|
+
bash scripts/install.sh [--version <tag>] [--prefix <dir>] [--repair]
|
|
14
15
|
|
|
15
16
|
Options:
|
|
16
17
|
--version <tag> Package tag/version to install (default: latest)
|
|
17
18
|
--prefix <dir> npm global prefix override
|
|
19
|
+
--repair Uninstall the registry package first to clear a stale global shim
|
|
18
20
|
-h, --help Show this help message
|
|
19
21
|
EOF
|
|
20
22
|
}
|
|
@@ -68,6 +70,10 @@ while [[ $# -gt 0 ]]; do
|
|
|
68
70
|
PREFIX="$2"
|
|
69
71
|
shift 2
|
|
70
72
|
;;
|
|
73
|
+
--repair)
|
|
74
|
+
REPAIR="true"
|
|
75
|
+
shift
|
|
76
|
+
;;
|
|
71
77
|
-h|--help)
|
|
72
78
|
usage
|
|
73
79
|
exit 0
|
|
@@ -88,6 +94,16 @@ if is_literal_install_spec "$PACKAGE_NAME"; then
|
|
|
88
94
|
else
|
|
89
95
|
INSTALL_SPEC="${PACKAGE_NAME}@${TARGET_VERSION}"
|
|
90
96
|
fi
|
|
97
|
+
|
|
98
|
+
if [[ "$REPAIR" == "true" ]]; then
|
|
99
|
+
REPAIR_CMD=(npm uninstall -g @unbrained/pm-cli)
|
|
100
|
+
if [[ -n "$PREFIX" ]]; then
|
|
101
|
+
REPAIR_CMD+=(--prefix "$PREFIX")
|
|
102
|
+
fi
|
|
103
|
+
echo "Repairing existing global pm install..."
|
|
104
|
+
"${REPAIR_CMD[@]}" >/dev/null 2>&1 || true
|
|
105
|
+
fi
|
|
106
|
+
|
|
91
107
|
# Force is required for idempotent reruns when an existing pm shim already exists.
|
|
92
108
|
INSTALL_CMD=(npm install -g --force "$INSTALL_SPEC")
|
|
93
109
|
if [[ -n "$PREFIX" ]]; then
|