-
Notifications
You must be signed in to change notification settings - Fork 0
56 lines (47 loc) · 1.5 KB
/
flake.yml
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
---
name: flake
"on":
workflow_dispatch:
schedule:
- cron: "0 8 * * 1"
permissions:
contents: write
pull-requests: write
jobs:
flake:
runs-on: ubuntu-latest
steps:
- name: Generate token
id: token
uses: tibdex/github-app-token@v2
with:
app_id: ${{ secrets.TOKEN_EXCHANGE_APP }}
installation_retrieval_mode: id
installation_retrieval_payload: ${{ secrets.TOKEN_EXCHANGE_INSTALL }}
private_key: ${{ secrets.TOKEN_EXCHANGE_KEY }}
permissions: >-
{"contents": "write", "pull_requests": "write"}
- name: Checkout source
id: source
uses: actions/checkout@v4
- name: Install nix
id: nix
uses: cachix/install-nix-action@v30
- name: Update flake
id: flake
uses: DeterminateSystems/update-flake-lock@v24
with:
commit-msg: "chore(flake): updated lockfile"
pr-title: "chore: automated flake update"
pr-body: "New flakelock generated, automerge should handle that!"
pr-labels: renovate
git-author-name: GitHub Actions
git-author-email: [email protected]
token: ${{ steps.token.outputs.token }}
- name: Enable automerge
id: automerge
if: steps.flake.outputs.pull-request-operation == 'created'
run: gh pr merge --rebase --auto "${{ steps.flake.outputs.pull-request-number }}"
env:
GH_TOKEN: ${{ steps.token.outputs.token }}
...