@catladder/cli 5.0.0 → 5.0.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.
@@ -21,6 +21,7 @@ RUN yarn global add \
21
21
  @semantic-release/git@11.0.0 \
22
22
  @semantic-release/changelog@7.0.0 \
23
23
  @semantic-release/gitlab@13.3.3 \
24
+ @semantic-release/github@12.0.9 \
24
25
  @semantic-release/exec@7.1.0
25
26
 
26
27
  RUN mkdir -p /scripts
@@ -40,10 +40,20 @@ fi
40
40
  echo "doing semantic release"
41
41
 
42
42
  if [ "$GITHUB_ACTIONS" = "true" ]; then
43
- # the gitlab publish plugin would fail on github; skip it (the tag
44
- # and changelog commit still happen, only the gitlab release entry
45
- # is gitlab-specific)
46
- PUBLISH_PLUGIN=""
43
+ # the github counterpart of the gitlab plugin below: it creates the
44
+ # entry on the releases page with the generated notes. Everything
45
+ # beyond that is switched off on purpose — commenting on the
46
+ # pull requests/issues of a release and labelling them would need
47
+ # `issues: write` / `pull-requests: write` on the release job, which
48
+ # only exists to release.
49
+ PUBLISH_PLUGIN=',
50
+ ["@semantic-release/github", {
51
+ "successComment": false,
52
+ "failComment": false,
53
+ "failTitle": false,
54
+ "labels": false,
55
+ "releasedLabels": false
56
+ }]'
47
57
  else
48
58
  # no gitlabUrl: the plugin derives it from the CI-provided variables
49
59
  # of the running instance. It used to be hardcoded to panter's gitlab,
@@ -52,6 +52,11 @@ workflows the same way (`▶️ catladder deploy`, `⏹️ catladder stop`,
52
52
 
53
53
  ## `method` — how the version is decided
54
54
 
55
+ Whichever method runs, the release ends the same way: a `vX.Y.Z` tag, a
56
+ `CHANGELOG.md` entry, a `chore(release): <version>` commit, and an
57
+ entry on the releases page of the git host (gitlab `/-/releases`,
58
+ github `/releases`) carrying the release notes.
59
+
55
60
  ### `semantic-release` (default)
56
61
  The version is derived automatically from **conventional commit
57
62
  messages** since the last release (`fix:` → patch, `feat:` → minor,
@@ -63,8 +68,10 @@ Developers declare changes intentionally as **`.changeset/*.md` files**
63
68
  (the official changesets format: a bump type + a human-written summary).
64
69
  The release job consumes all pending changesets, takes the highest bump,
65
70
  computes the next version from the last `v*` git tag, writes the
66
- changelog, commits `chore(release): <version>`, and pushes the tag. An
67
- empty `.changeset/` folder means there is nothing to release.
71
+ changelog, commits `chore(release): <version>`, pushes the tag and
72
+ creates the release entry on the git host (gitlab `/-/releases`,
73
+ github `/releases`) with the changelog as its description. An empty
74
+ `.changeset/` folder means there is nothing to release.
68
75
 
69
76
  Add a changeset by creating `.changeset/<name>.md`:
70
77
 
@@ -121,6 +128,13 @@ the `security` commands in the `catladder-cli` reference.
121
128
  MR adding a changeset describing the accumulated work.
122
129
  - Wrong version bump → check commit types (semantic-release) or the bump
123
130
  levels in the changeset files (changesets).
131
+ - Tag pushed but nothing on the releases page → with `changesets` the
132
+ entry is created via the host api after the push and never fails the
133
+ job (the release itself is done); look for the `could not create the
134
+ release entry` warning at the end of the release job log. On gitlab
135
+ it needs `GL_TOKEN` (`catladder project renew-token`). Releases
136
+ tagged before catladder created entries have none — that is not fixed
137
+ retroactively, create them by hand from the tag.
124
138
  - Inspect the job with `yarn catladder project ci job-log` (see the
125
139
  `catladder-cli` skill).
126
140
 
@@ -21,6 +21,7 @@ RUN yarn global add \
21
21
  @semantic-release/git@11.0.0 \
22
22
  @semantic-release/changelog@7.0.0 \
23
23
  @semantic-release/gitlab@13.3.3 \
24
+ @semantic-release/github@12.0.9 \
24
25
  @semantic-release/exec@7.1.0
25
26
 
26
27
  RUN mkdir -p /scripts
@@ -40,10 +40,20 @@ fi
40
40
  echo "doing semantic release"
41
41
 
42
42
  if [ "$GITHUB_ACTIONS" = "true" ]; then
43
- # the gitlab publish plugin would fail on github; skip it (the tag
44
- # and changelog commit still happen, only the gitlab release entry
45
- # is gitlab-specific)
46
- PUBLISH_PLUGIN=""
43
+ # the github counterpart of the gitlab plugin below: it creates the
44
+ # entry on the releases page with the generated notes. Everything
45
+ # beyond that is switched off on purpose — commenting on the
46
+ # pull requests/issues of a release and labelling them would need
47
+ # `issues: write` / `pull-requests: write` on the release job, which
48
+ # only exists to release.
49
+ PUBLISH_PLUGIN=',
50
+ ["@semantic-release/github", {
51
+ "successComment": false,
52
+ "failComment": false,
53
+ "failTitle": false,
54
+ "labels": false,
55
+ "releasedLabels": false
56
+ }]'
47
57
  else
48
58
  # no gitlabUrl: the plugin derives it from the CI-provided variables
49
59
  # of the running instance. It used to be hardcoded to panter's gitlab,
@@ -52,6 +52,11 @@ workflows the same way (`▶️ catladder deploy`, `⏹️ catladder stop`,
52
52
 
53
53
  ## `method` — how the version is decided
54
54
 
55
+ Whichever method runs, the release ends the same way: a `vX.Y.Z` tag, a
56
+ `CHANGELOG.md` entry, a `chore(release): <version>` commit, and an
57
+ entry on the releases page of the git host (gitlab `/-/releases`,
58
+ github `/releases`) carrying the release notes.
59
+
55
60
  ### `semantic-release` (default)
56
61
  The version is derived automatically from **conventional commit
57
62
  messages** since the last release (`fix:` → patch, `feat:` → minor,
@@ -63,8 +68,10 @@ Developers declare changes intentionally as **`.changeset/*.md` files**
63
68
  (the official changesets format: a bump type + a human-written summary).
64
69
  The release job consumes all pending changesets, takes the highest bump,
65
70
  computes the next version from the last `v*` git tag, writes the
66
- changelog, commits `chore(release): <version>`, and pushes the tag. An
67
- empty `.changeset/` folder means there is nothing to release.
71
+ changelog, commits `chore(release): <version>`, pushes the tag and
72
+ creates the release entry on the git host (gitlab `/-/releases`,
73
+ github `/releases`) with the changelog as its description. An empty
74
+ `.changeset/` folder means there is nothing to release.
68
75
 
69
76
  Add a changeset by creating `.changeset/<name>.md`:
70
77
 
@@ -121,6 +128,13 @@ the `security` commands in the `catladder-cli` reference.
121
128
  MR adding a changeset describing the accumulated work.
122
129
  - Wrong version bump → check commit types (semantic-release) or the bump
123
130
  levels in the changeset files (changesets).
131
+ - Tag pushed but nothing on the releases page → with `changesets` the
132
+ entry is created via the host api after the push and never fails the
133
+ job (the release itself is done); look for the `could not create the
134
+ release entry` warning at the end of the release job log. On gitlab
135
+ it needs `GL_TOKEN` (`catladder project renew-token`). Releases
136
+ tagged before catladder created entries have none — that is not fixed
137
+ retroactively, create them by hand from the tag.
124
138
  - Inspect the job with `yarn catladder project ci job-log` (see the
125
139
  `catladder-cli` skill).
126
140