Skip to content

Commit b0a9e7b

Browse files
committed
fix: test markdown release notes in slack
1 parent 84d3b6d commit b0a9e7b

File tree

2 files changed

+38
-2
lines changed

2 files changed

+38
-2
lines changed

adminforth/documentation/blog/2025-01-09-how-adminforth-manages-version/index.md

Lines changed: 37 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,6 @@ steps:
145145
- /var/run/docker.sock:/var/run/docker.sock
146146
commands:
147147
- npm clean-install
148-
- npm run build
149148
- npm audit signatures
150149
- npx semantic-release
151150
secrets:
@@ -267,4 +266,40 @@ git merge next
267266
git push
268267
```
269268

270-
This will trigger release `v1.2.0` because we merged `next` to `main` and it was a feature release.
269+
This will trigger release `v1.2.0` because we merged `next` to `main` and it was a feature release.
270+
271+
272+
## Slack notifications
273+
274+
So now we have automatic releases with release notes on GitHub.
275+
For our internal team we use Slack and we want to get notifications about releases there.
276+
277+
```
278+
npm i -D semantic-release-slack-bot
279+
```
280+
281+
Into "release" section of `package.json` add:
282+
283+
```
284+
[
285+
"@semantic-release/slack",
286+
{
287+
...
288+
}
289+
],
290+
```
291+
292+
293+
Also create channel in Slack, click on channel name, "Integrations" -> "Add an App" -> "Incoming Webhooks" -> "Add to Slack" -> "Add Incoming Webhook to Workspace" -> "Add to Slack" -> "Copy Webhook URL"
294+
295+
Add it to Woodpecker as secret `SLACK_WEBHOOK` environment variable.
296+
297+
Also add this secterd to `.woodpecker.yml`:
298+
299+
```
300+
secrets:
301+
- GITHUB_TOKEN
302+
- NPM_TOKEN
303+
//diff-add
304+
- SLACK_WEBHOOK
305+
```

adminforth/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@
4040
"semantic-release-slack-bot",
4141
{
4242
"notifyOnSuccess": true,
43+
"markdownReleaseNotes": true,
4344
"notifyOnFail": true
4445
}
4546
]

0 commit comments

Comments
 (0)