This commit is contained in:
parent
61f320174e
commit
9c3d1c9c0d
5 changed files with 115 additions and 78 deletions
|
@ -1,8 +1,11 @@
|
|||
on: [push]
|
||||
on:
|
||||
push:
|
||||
branches: ["*"]
|
||||
jobs:
|
||||
test:
|
||||
runs-on: nix
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- run: cat /nix/store/cscv53kqarckmbz6729ngmyxg3y53n9c-push-to-cache.sh
|
||||
- run: nix-fast-build --no-nom
|
||||
name: Checkout repository
|
||||
- name: Build with nix
|
||||
run: nix-fast-build --no-nom
|
||||
|
|
|
@ -1,17 +1,35 @@
|
|||
name: update-flake-lock
|
||||
on:
|
||||
schedule:
|
||||
- cron: '27 1 * * 6'
|
||||
- cron: '45 14 * * *' # daily at 14:30
|
||||
|
||||
jobs:
|
||||
lockfile:
|
||||
runs-on: nix
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Update flake.lock
|
||||
uses: https://github.com/3DeterminateSystems/update-flake-lock@main
|
||||
name: Checkout repository
|
||||
with:
|
||||
pr-title: "Update flake.lock" # Title of PR to be created
|
||||
pr-labels: | # Labels to be set on the PR
|
||||
dependencies
|
||||
automated
|
||||
token: ${{secrets.SEVENOFNINE_TOKEN}}
|
||||
- name: Create new branch from the checked out one
|
||||
run: git switch -c update-flake-lock
|
||||
- name: Configure git as `Seven of Nix`
|
||||
run: |
|
||||
git config --global user.email "sevenofnine+andrea.ciceri@autistici.org"
|
||||
git config --global user.name "Seven of Nine"
|
||||
- name: Update flake's lockfile and create commit
|
||||
run: nix flake update --commit-lock-file
|
||||
- name: Push commit to the `update-flake-lock` remote branch
|
||||
run: git push origin --force update-flake-lock
|
||||
- name: Login as `Seven of Nix`
|
||||
run: |
|
||||
tea logins add --token ${{secrets.SEVENOFNINE_TOKEN}} --url https://git.aciceri.dev
|
||||
tea logins default git.aciceri.dev
|
||||
- name: Create the pull request
|
||||
run: |
|
||||
tea pulls create \
|
||||
--repo "$GITHUB_REPOSITORY" \
|
||||
--title "Update flake's lockfile" \
|
||||
--description "Check the commit description for inputs deltas" \
|
||||
--assignees aciceri \
|
||||
|| echo "PR already existing"
|
||||
|
|
Reference in a new issue