feat: add working forms #45
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Format front- and backend | |
| on: | |
| push: | |
| workflow_dispatch: | |
| jobs: | |
| format: | |
| permissions: write-all | |
| runs-on: 'ubuntu-24.04' | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| with: | |
| token: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Setup Bun | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version: latest | |
| - name: Setup Rust stable | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Install frontend dependencies | |
| run: bun i | |
| - name: Format frontend | |
| run: bun format:ci | |
| - name: Format backend | |
| run: | | |
| shopt -s globstar | |
| rustfmt --edition 2021 episko_cli/src/**/*.rs | |
| rustfmt --edition 2021 episko_derive/src/**/*.rs | |
| rustfmt --edition 2021 episko_gui_backend/src/**/*.rs | |
| rustfmt --edition 2021 episko_lib/src/**/*.rs | |
| - name: Commit and push changes | |
| uses: EndBug/add-and-commit@v9 | |
| with: | |
| add: '.' | |
| message: '[Actions] style: improve formatting [skip ci]' | |
| author_name: github-actions[bot] | |
| committer_name: github-actions[bot] | |
| author_email: github-actions[bot]@github.com | |
| committer_email: github-actions[bot]@github.com |