Skip to content

Commit

Permalink
chore(ci): trunk conf (#6)
Browse files Browse the repository at this point in the history
* ci(repository): enable issues

* ci: recommend conventional commits vscode extension

* ci: recommand github actions and PR vscode extensions

* ci: require ZERO PR approvals

* chore: typo

* ci: enable and configure trunk.io

* chore: typo

* Merge branch 'main' of https://github.com/constructions-incongrues/plomberie into trivoallan/issue2

* feat(ci): code quality checks with trunk.io

Fixes #2

* chore: forgotten in previous commit

* ci(repository): make trunk checks required for PR merge
  • Loading branch information
trivoallan authored Oct 6, 2024
1 parent 7f71ad9 commit 4b35829
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 8 deletions.
12 changes: 4 additions & 8 deletions .github/settings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,10 @@ repository:
- boilerplate
visibility: public
has_issues: true #
has_issues: true #
has_projects: false
has_wiki: false
has_discussions: false
is_template: true
is_template: true
default_branch: main
allow_squash_merge: true
allow_merge_commit: false
Expand Down Expand Up @@ -41,12 +39,10 @@ branches:
# required_approving_review_count: 1
# dismiss_stale_reviews: true
# require_code_owner_reviews: true
required_status_checks:
~ # null to disable
# strict: true
# contexts:
# - Check dist/
# - TypeScript Tests
required_status_checks: # null to disable
strict: true
contexts:
- Trunk Check
enforce_admins: true
restrictions: null
required_linear_history: true
Expand Down
23 changes: 23 additions & 0 deletions .github/workflows/trunk-check.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Pull Request

on: [pull_request]
concurrency:
group: ${{ github.head_ref || github.run_id }}
cancel-in-progress: true

permissions: read-all

jobs:
trunk_check:
name: Trunk Code Quality Runner
runs-on: ubuntu-latest
permissions:
checks: write # For trunk to post annotations
contents: read # For repo checkout

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Trunk Code Quality
uses: trunk-io/trunk-action@v1
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

## Features

- [ ] Code quality checks using [trunk.io](https://trunk.io/code-quality)
- [ ] Github Flow
- [ ] Code quality checks using [trunk.io](https://trunk.io/code-quality)
- [ ] main branch deploys to github pages
Expand Down

0 comments on commit 4b35829

Please sign in to comment.