Skip to content

Commit 80bebd5

Browse files
committed
ci: tweak GitHub action workflows
1 parent bee8237 commit 80bebd5

File tree

4 files changed

+30
-26
lines changed

4 files changed

+30
-26
lines changed

.github/workflows/build-and-bump.yml

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
name: Build, minify, lower syntax, bump versions, update download counts & changelog
1+
name: Build and bump
22

33
on:
44
push:
55
branches: [main]
66
paths:
7-
- source/** # only trigger when source files were changed
8-
- .github/workflows/build-and-bump.yml # or on updates to this file itself
9-
workflow_dispatch: # allows manual triggering on GitHub
7+
- source/**
8+
- .github/workflows/build-and-bump.yml
9+
workflow_dispatch:
1010

1111
permissions:
1212
contents: write
@@ -43,7 +43,12 @@ jobs:
4343
npx lightningcss --minify --browserslist \
4444
--output-file="./theme.css" -- "./theme.css" || exit 1
4545
46-
# check for unsupported features via `doiuse`
46+
# append style-settings (last, so not removed by minification)
47+
cat <(echo && echo "/* @settings") ./source/style-settings.yaml <(echo "*/") \
48+
>> ./theme.css
49+
50+
- name: check for unsupported features
51+
run: |
4752
violations=$(npx doiuse --browsers="$BROWSERSLIST" \
4853
--config="./.doiuse-ignore.json" theme.css)
4954
if [[ -n "$violations" ]]; then # `doiuse` does not exit with non-zero code
@@ -52,10 +57,6 @@ jobs:
5257
exit 1
5358
fi
5459
55-
# append style-settings (last, so not removed by minification)
56-
cat <(echo && echo "/* @settings") ./source/style-settings.yaml <(echo "*/") \
57-
>> ./theme.css
58-
5960
- name: bump version in manifest
6061
run: |
6162
version=$(grep --max-count=1 '"version"' "./manifest.json" | cut -d'"' -f4 | cut -d'.' -f2)
@@ -71,13 +72,13 @@ jobs:
7172
- name: update changelog
7273
run: |
7374
git log :/bump.. --format="- %cs %s" | # commits since last `bump` commit
74-
grep -vE "build|ci|refactor|style|bump" | # don't include internal changes
75+
grep -vE "build|ci||style|bump" | # don't include internal changes
7576
sed -E "s/^(- [0-9-]+) ([^ ]+): /\1 **\2**: /" >> "temp.md" # bold cc keyword
7677
grep -v "^$" "Changelog.md" >> "temp.md"
7778
mv -f "temp.md" "Changelog.md"
7879
7980
- name: commit
8081
uses: stefanzweifel/git-auto-commit-action@v5
8182
with:
82-
commit_message: "bump: version & update changelog"
83+
commit_message: "bump: version bump & changelog update"
8384
branch: ${{ github.head_ref }}

.github/workflows/semantic-pr-title.yml

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,29 @@
1-
name: Ensure Conventional Commits-like PR titles
1+
name: PR title
22

33
on:
44
pull_request_target:
5-
types: [opened, edited, synchronize]
5+
types:
6+
- opened
7+
- edited
8+
- synchronize
9+
- reopened
10+
- ready_for_review
611

712
permissions:
813
pull-requests: read
914

1015
jobs:
1116
semantic-pull-request:
12-
name: Validate PR title
17+
name: Check PR title
1318
runs-on: ubuntu-latest
1419
steps:
1520
- uses: amannn/action-semantic-pull-request@v5
16-
# add `improv` to the list of allowed types
21+
env:
22+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
1723
with:
18-
types: |
24+
requireScope: false
25+
subjectPattern: ^(?![A-Z]).+$ # disallow title starting with capital
26+
types: | # add `improv` to the list of allowed types
1927
improv
2028
fix
2129
feat
@@ -29,5 +37,3 @@ jobs:
2937
docs
3038
break
3139
revert
32-
env:
33-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/stale-bot.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: "Close stale issues and PRs"
1+
name: Stale bot
22
on:
33
schedule:
44
- cron: "18 04 * * 3"
@@ -11,12 +11,12 @@ jobs:
1111
stale:
1212
runs-on: ubuntu-latest
1313
steps:
14-
- name: Close Stale Issues
14+
- name: Close stale issues
1515
uses: actions/stale@v9
1616
with:
1717
repo-token: ${{ secrets.GITHUB_TOKEN }}
1818

19-
# DOCS https://github.com/actions/stale?tab=readme-ov-file#all-options
19+
# DOCS https://github.com/actions/stale#all-options
2020
days-before-stale: 180 # ~6 months
2121
days-before-close: 7
2222
stale-issue-label: "Stale"

Changelog.md

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,14 @@
44
- 2024-12-15 **feat**: setting to hide the status bar icon of the Harper plugin
55
- 2024-12-15 **docs**: improve some phrasing
66
- 2024-12-11 **chore**: tweak headings in longform notes
7-
- 2024-12-11 **chore**: consistent file naming convention
8-
- 2024-12-09 **docs**: update badges
97
- 2024-12-09 **docs**: formatting and minor fixes
10-
- 2024-12-09 **feat**: new color scheme Gruvbox Light
11-
- 2024-12-09 **feat**: new colorscheme `Gruvbox Dark`
8+
- 2024-12-09 **feat**: new color scheme `Gruvbox Light`
9+
- 2024-12-09 **feat**: new color scheme `Gruvbox Dark`
1210
- 2024-12-06 **chore**: do not override callout icons (#320)
1311
- 2024-11-22 **fix**: make link to relevant section of readme go to the correct place
1412
- 2024-11-20 **feat**: add infobox on submission of own color scheme
1513
- 2024-11-18 **feat!**: alternative color schemes
1614
- 2024-11-17 **fix**: reduce indentation of unordered lists in callouts
17-
- 2024-11-17 **chore**: rename `just` tasks
1815
- 2024-11-12 **fix**: better contrast for success/error notifications
1916
- 2024-11-07 **fix**: remove outdated vault launch styling
2017
- 2024-11-04 **feat**: styling of success notices

0 commit comments

Comments
 (0)