@anselmdk/feature-spec-md 0.2.1-rc.1 → 0.3.0

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/docs/releasing.md +31 -70
  2. package/package.json +1 -1
package/docs/releasing.md CHANGED
@@ -6,16 +6,15 @@ Bare semver tags are valid git tags and match the package version exactly. The `
6
6
 
7
7
  ## Release Candidate
8
8
 
9
- Use an RC when you want a testable npm package for the next release without updating the `latest` npm dist-tag.
9
+ Use an RC when you want a testable npm package for the next release without updating the `latest` npm dist-tag or permanently changing the repository version.
10
10
 
11
- 1. Make sure `main` contains the intended final version in `package.json` and `package-lock.json`.
12
- - For the next minor release from `0.1.1`, the base version should be `0.2.0`.
13
- - For the next major release from `0.2.0`, the base version should be `1.0.0`.
11
+ 1. Make sure `main` contains the intended stable base version in `package.json` and `package-lock.json`.
12
+ - For a release candidate for `0.2.1`, the base version should be `0.2.1`.
13
+ - For a release candidate for `0.3.0`, the base version should be `0.3.0`.
14
14
  2. Open GitHub Actions.
15
- 3. Run the `Publish to npm` workflow from `main`.
16
- 4. Choose `rc` for the release type.
17
- 5. Keep the RC number at `1` for the first release candidate, or increase it manually for later candidates.
18
- 6. The workflow runs verification, changes the package version only inside the workflow to `<base>-rc.<number>`, and publishes it with the npm `rc` dist-tag.
15
+ 3. Run the `Publish RC to npm` workflow from `main`.
16
+ 4. Keep the RC number at `1` for the first release candidate, or increase it manually for later candidates.
17
+ 5. The workflow runs verification, changes the package version only inside the workflow to `<base>-rc.<number>`, publishes it with the npm `rc` dist-tag, and writes the published version to the run summary.
19
18
 
20
19
  Install the latest RC with:
21
20
 
@@ -26,83 +25,45 @@ npm install @anselmdk/feature-spec-md@rc
26
25
  Install a specific RC with:
27
26
 
28
27
  ```bash
29
- npm install @anselmdk/feature-spec-md@0.2.0-rc.1
28
+ npm install @anselmdk/feature-spec-md@0.2.1-rc.1
30
29
  ```
31
30
 
32
- Repeat the workflow as needed. Increase the RC number for each published candidate so npm receives a unique version, for example `0.2.0-rc.2`, and the workflow moves the `rc` dist-tag to that version.
31
+ Repeat the workflow as needed. Increase the RC number for each published candidate so npm receives a unique version, for example `0.2.1-rc.2`, and the workflow moves the `rc` dist-tag to that version.
33
32
 
34
- ## Stable Minor Release
33
+ ## Stable Release
35
34
 
36
- Use this for backward-compatible features.
35
+ Use a stable release when you want to publish the next package version to the npm `latest` dist-tag.
37
36
 
38
- 1. Start from a clean branch based on `main`.
39
- 2. Bump the package version:
37
+ 1. Open GitHub Actions.
38
+ 2. Run the `Publish Stable to npm` workflow from `main`.
39
+ 3. Choose the version bump:
40
+ - `patch`, for example `0.2.1` -> `0.2.2`.
41
+ - `minor`, for example `0.2.1` -> `0.3.0`.
42
+ - `major`, for example `0.2.1` -> `1.0.0`.
43
+ 4. The workflow runs verification, bumps `package.json` and `package-lock.json`, commits the release version, creates a bare semver git tag, pushes the commit and tag, publishes the package with the npm `latest` dist-tag, and writes the published version to the run summary.
40
44
 
41
- ```bash
42
- npm version minor --no-git-tag-version
43
- ```
45
+ You do not need to manually run `npm version`, edit `package.json`, edit `package-lock.json`, or create a git tag for stable releases. The workflow does that for you.
44
46
 
45
- 3. Run verification locally:
47
+ Install the latest stable version with:
46
48
 
47
- ```bash
48
- npm run verify
49
- npm run format
50
- ```
51
-
52
- 4. Open and merge a pull request containing the version bump and any release notes.
53
- 5. After the PR is merged, update local `main` and create a bare semver tag that exactly matches `package.json`:
54
-
55
- ```bash
56
- git checkout main
57
- git pull --ff-only
58
- git tag 0.2.0
59
- git push origin 0.2.0
60
- ```
61
-
62
- 6. Confirm the `Publish to npm` workflow succeeds.
63
-
64
- The workflow validates that the tag is a stable semver version and exactly matches `package.json` before publishing to npm with the `latest` dist-tag.
65
-
66
- ## Stable Major Release
67
-
68
- Use this for breaking changes.
69
-
70
- 1. Document the breaking changes in the release PR.
71
- 2. Bump the package version:
72
-
73
- ```bash
74
- npm version major --no-git-tag-version
75
- ```
76
-
77
- 3. Run verification locally:
78
-
79
- ```bash
80
- npm run verify
81
- npm run format
82
- ```
83
-
84
- 4. Open and merge the release PR.
85
- 5. Tag the merged commit with the exact version, for example:
49
+ ```bash
50
+ npm install @anselmdk/feature-spec-md@latest
51
+ ```
86
52
 
87
- ```bash
88
- git checkout main
89
- git pull --ff-only
90
- git tag 1.0.0
91
- git push origin 1.0.0
92
- ```
53
+ Install the exact version reported by the workflow summary, for example:
93
54
 
94
- 6. Confirm the `Publish to npm` workflow succeeds.
55
+ ```bash
56
+ npm install @anselmdk/feature-spec-md@0.2.2
57
+ ```
95
58
 
96
59
  ## npm Publishing Setup
97
60
 
98
- The publish workflows are ready for npm provenance. The best setup is npm trusted publishing with GitHub Actions OIDC, which avoids long-lived npm publish tokens.
61
+ The publish workflows are ready for npm provenance. If you publish with an npm token, keep the `NPM_TOKEN` repository secret configured.
99
62
 
100
- On npmjs.com, configure this package with trusted publishing:
63
+ If you use npm trusted publishing instead of `NPM_TOKEN`, configure npmjs.com for the workflow files that publish this package:
101
64
 
102
65
  - Publisher: GitHub Actions
103
66
  - Repository owner: `anselmdk`
104
67
  - Repository name: `feature-spec-md`
105
- - Workflow filename: `publish.yml`
106
- - Allowed action: `npm publish`
107
-
108
- If trusted publishing is not configured yet, the workflow can still use the `NPM_TOKEN` repository secret. Keep RC and stable publishing in the same workflow because npm trusted publishing allows only one trusted publisher workflow per package.
68
+ - Workflow filename: `publish-rc.yml` for RC publishing
69
+ - Workflow filename: `publish-stable.yml` for stable publishing
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@anselmdk/feature-spec-md",
3
- "version": "0.2.1-rc.1",
3
+ "version": "0.3.0",
4
4
  "description": "Markdown specs for AI-assisted, testable spec driven development across model, feature, stack, and design documents.",
5
5
  "type": "module",
6
6
  "repository": {