WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

chore: update flakes (#776) #276

chore: update flakes (#776)

chore: update flakes (#776) #276

Workflow file for this run

name: Format
on:
push:
branches:
- "main"
- "release-*"
workflow_dispatch:
jobs:
nix:
name: Nix files
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v6
with:
token: ${{ secrets.PUSH_TOKEN }}
- name: Set Git user info
run: |
git config user.name 'github-actions[bot]'
git config user.email 'github-actions[bot]@users.noreply.github.com'
- name: Get short revision
id: rev
run: echo "rev=$(git rev-parse --short HEAD)" >> "$GITHUB_OUTPUT"
- name: Install Nix
uses: cachix/install-nix-action@v31
- name: Format Nix files
run: |
nix fmt
- name: Install Node modules
run: |
nix develop --command pnpm install
- name: Format with Prettier
run: |
nix develop --command nrr fmt
- name: Commit changes
run: |
if ! git diff --color=always --exit-code; then
git commit -am "style: format ${{ steps.rev.outputs.rev }}"
git push
fi