-
Notifications
You must be signed in to change notification settings - Fork 0
39 lines (33 loc) · 1.23 KB
/
flake-update.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: update flake lock
on:
workflow_dispatch:
schedule:
- cron: '0 2 * * *'
jobs:
update:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install nix
uses: DeterminateSystems/nix-installer-action@v13
- name: Update flake lock
uses: DeterminateSystems/update-flake-lock@v23
id: update-flake-lock
with:
git-author-name: 'github-actions[bot]'
git-author-email: 'github-actions[bot]@users.noreply.github.com'
git-committer-name: 'github-actions[bot]'
git-committer-email: 'github-actions[bot]@users.noreply.github.com'
env:
GIT_COMMIT_MESSAGE: "chore(nixos): flake update"
- name: Nix flake check
if: ${{ steps.update-flake-lock.outputs.pull-request-operation == 'created' }}
run: gh workflow run build.yaml --ref update_flake_lock_action
env:
GH_TOKEN: ${{ github.token }}
- name: Automerge
if: ${{ steps.update-flake-lock.outputs.pull-request-operation == 'created' }}
run: "gh pr merge --auto --merge ${{ steps.update.outputs.pull-request-number }}"
env:
GH_TOKEN: ${{ github.token }}