Skip to content

started moving timer tests #100

started moving timer tests

started moving timer tests #100

Workflow file for this run

name: Scalafmt
on:
pull_request:
branches:
- main
push:
branches:
- main
jobs:
scalafmt:
# Do not run on PRs / pushes from the bot (commit marked with [gh-bot])
if: ${{ !contains(github.event.head_commit.message, '[gh-bot]') }}
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
fetch-depth: 0 # Fetch full history for proper blame tracking
token: ${{ secrets.REPO_TOKEN }} # Use the token for authentication
submodules: recursive
- name: Set up JDK
uses: actions/setup-java@v3
with:
distribution: "temurin"
java-version: "17"
- name: Install Coursier
run: |
curl -fLo cs https://git.io/coursier-cli-linux && chmod +x cs
- name: Install Scalafmt
run: |
./cs install scalafmt
- name: Run & Commit and push changes
if: ${{ github.ref == 'refs/heads/main' }} # Only commit on main branch
run: |
/home/runner/.local/share/coursier/bin/scalafmt --non-interactive --diff-branch main
git config --global user.name "github-actions[bot]"
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git add .
git commit -m "[gh-bot] Apply Scalafmt formatting"
git push https://${{ secrets.REPO_TOKEN }}@github.com/${{ github.repository }}.git HEAD:main