CI #23
This file contains 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: CI | |
on: | |
push: | |
branches: [master] | |
pull_request: | |
branches: [master] | |
schedule: | |
- cron: '0 0 * * 2,5' # every Tuesday & Friday | |
permissions: write-all | |
jobs: | |
build: | |
runs-on: [ ubuntu-latest ] | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: DeterminateSystems/nix-installer-action@main | |
with: | |
github-token: ${{ secrets.GH_TOKEN }} | |
extra-conf: "experimental-features = nix-command flakes pipe-operators" | |
- uses: DeterminateSystems/magic-nix-cache-action@main | |
with: | |
use-flakehub: false | |
- uses: cachix/cachix-action@master | |
with: | |
name: fmcachix | |
# If you chose API tokens for write access OR if you have a private cache | |
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' | |
- run: nix build .#simple --verbose | |
lockfile: | |
runs-on: [ubuntu-latest] | |
if: ${{ github.event_name == 'schedule' }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: DeterminateSystems/nix-installer-action@main | |
with: | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
extra-conf: experimental-features = nix-command flakes auto-allocate-uids configurable-impure-env | |
- uses: DeterminateSystems/update-flake-lock@v24 | |
name: Update flake.lock | |
with: | |
branch: nightly-update | |
token: ${{ secrets.GITHUB_TOKEN }} | |
git-author-name: 'little fmway' | |
git-author-email: '[email protected]' | |
git-committer-name: 'little fmway' | |
git-committer-email: '[email protected]' | |
commit-msg: 'chore(lockfile): update flake.lock' | |
pr-title: 'chore(lockfile): update flake.lock' | |
pr-labels: | | |
dependencies | |
automated | |
auto-merge: | |
needs: [ build ] | |
runs-on: ubuntu-latest | |
if: ${{ github.event_name == 'pull_request' }} | |
steps: | |
- run: gh pr merge --auto --merge "$PR_URL" | |
env: | |
PR_URL: ${{github.event.pull_request.html_url}} | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |