Skip to content

Commit

Permalink
chore: stick to version majors
Browse files Browse the repository at this point in the history
Reduce the update noise by only using majors in CI.
While at it, use Bun to validate renovate config and run prettier;
shaves a few seconds off runtime.

Finally, add a job that looks for typos.
  • Loading branch information
jbergstroem committed Feb 5, 2024
1 parent 8526577 commit f2b9e9d
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 14 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/dockerhub.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- name: Run shell script
run: sh/generate-dockerhub-readme.sh
- name: Update Docker Hub readme and description
uses: peter-evans/dockerhub-description@v4.0.0
uses: peter-evans/dockerhub-description@v4
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
Expand Down
32 changes: 20 additions & 12 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,11 @@ jobs:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: validate
uses: rinchsan/[email protected]
with:
pattern: ".github/renovate.json"
- uses: oven-sh/setup-bun@v1
- run: bun install -g renovate
- name: Validate config
run: renovate-config-validator .github/renovate.json

shellcheck:
runs-on: ubuntu-22.04
name: Shellcheck
Expand All @@ -25,14 +26,16 @@ jobs:
run: |
echo "::add-matcher::.github/matcher-shellcheck.json"
shellcheck -x -f gcc -S warning sh/*.sh test/*.{sh,bash}
hadolint:
runs-on: ubuntu-22.04
name: Hadolint
steps:
- uses: actions/checkout@v4
- uses: jbergstroem/hadolint-gh-action@v1.12.1
- uses: jbergstroem/hadolint-gh-action@v1
with:
error_level: 2

actionlint:
name: Actionlint
runs-on: ubuntu-22.04
Expand All @@ -46,18 +49,15 @@ jobs:
run: |
echo "::add-matcher::.github/matcher-actionlint.json"
actionlint -color
prettier:
runs-on: ubuntu-22.04
name: Prettier
steps:
- uses: actions/checkout@v4
- uses: actions/[email protected]
with:
node-version: "18.11.0"
- name: Install prettier
run: npm install -g prettier
- name: Run prettier
run: prettier -c .
- uses: oven-sh/setup-bun@v1
- run: bunx prettier -c .

shfmt:
name: Shfmt
runs-on: ubuntu-22.04
Expand All @@ -69,3 +69,11 @@ jobs:
run: curl -Ls -o shfmt "https://github.com/mvdan/sh/releases/download/v${{ env.version }}/shfmt_v${{ env.version }}_linux_amd64" && chmod +x shfmt && sudo mv shfmt /usr/local/bin
- name: Lint shell scripts
run: shfmt -i 2 -d sh/*.sh test/*.sh

typos:
name: Typos
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: Check for typos
uses: crate-ci/[email protected]
1 change: 1 addition & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ jobs:
run: |
[[ $(git tag -l "${{ steps.extract.outputs.tag }}") || $(curl -L -s "${{ env.TAG_URL }}" | jq -r '.results[] | select(.name=="${{ steps.extract.outputs.tag }}")') ]] && \
echo "Tag already exists. Quitting." && exit 1 || exit 0
test:
name: Run e2e tests
needs:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/todo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: TODO to Issue
uses: alstr/todo-to-issue-action@v4.12.1
uses: alstr/todo-to-issue-action@v4
with:
CLOSE_ISSUES: false

0 comments on commit f2b9e9d

Please sign in to comment.