Skip to content

Commit 4f5e2f7

Browse files
committed
build: include an automatic version bump to docs when updating
1 parent 89c89c5 commit 4f5e2f7

2 files changed

Lines changed: 6 additions & 11 deletions

File tree

.github/maintainers_guide.md

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -46,28 +46,22 @@ $ git checkout -b v1.2.3
4646
$ npm version <major|minor|patch> --no-git-tag-version
4747
```
4848

49-
4. Update all references to versions in documentation and the workflow files in `example-workflows/` to the latest version:
50-
51-
```sh
52-
$ grep -rl 'slackapi/[email protected]' ./docs ./example-workflows | xargs sed -i 's|slackapi/[email protected]|slackapi/[email protected]|g'
53-
```
54-
55-
5. Run all tests with the latest dependencies to make sure tests pass:
49+
4. Run all tests with the latest dependencies to make sure tests pass:
5650

5751
```sh
5852
$ npm ci
5953
$ npm test
6054
```
6155

62-
6. Commit the changes on your release branch and open a pull request with relevant labels:
56+
5. Commit the changes on your release branch and open a pull request with relevant labels:
6357

6458
```sh
6559
$ git commit -m "chore(release): tag version 1.2.3"
6660
$ git push -u origin v1.2.3
6761
```
6862

69-
7. After merging these changes into `main` create a new [release](https://github.com/slackapi/slack-github-action/releases/new) with a new tag - `v1.2.3` - on publish. Include relevant changes in the release notes!
70-
8. Once released, make sure to close the relevant GitHub Milestone for the version you released.
63+
6. After merging these changes into `main` create a new [release](https://github.com/slackapi/slack-github-action/releases/new) with a new tag - `v1.2.3` - on publish. Include relevant changes in the release notes!
64+
7. Once released, make sure to close the relevant GitHub Milestone for the version you released.
7165

7266
## Workflow
7367

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@
1010
"dev": "act public --eventpath .github/resources/.actions/event.json --secret-file .github/resources/.env --platform ubuntu-latest=node:20-buster --container-architecture linux/amd64",
1111
"lint:fix": "biome check --write",
1212
"lint": "biome check",
13-
"test": "c8 mocha test/*.spec.js"
13+
"test": "c8 mocha test/*.spec.js",
14+
"version": "TAG=\"v$(npm pkg get version | jq -r)\" && grep -rl 'slackapi/slack-github-action@v' ./docs ./example-workflows | xargs sed -i \"s|slackapi/slack-github-action@v.*|slackapi/slack-github-action@${TAG}|g\""
1415
},
1516
"repository": {
1617
"type": "git",

0 commit comments

Comments
 (0)