Skip to content

Commit 4f310a8

Browse files
authored
Merge pull request #5432 from input-output-hk/update-hackage-and-chap-action
Add GitHub Action to periodically update Hackage and CHaP
2 parents fbe2ff2 + 3c1515b commit 4f310a8

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: Update Hackage and CHaP
2+
3+
on:
4+
workflow_dispatch: # allows manual triggering
5+
schedule:
6+
- cron: '0 0 * * 0' # runs weekly on Sunday at 00:00
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Install Nix
13+
uses: cachix/install-nix-action@v18
14+
with:
15+
# Use last stable nixos channel and the same nix as in channel:
16+
install_url: https://releases.nixos.org/nix/nix-2.11.1/install
17+
nix_path: nixpkgs=channel:nixos-22.11
18+
github_access_token: ${{ secrets.GITHUB_TOKEN }}
19+
extra_nix_config: |
20+
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }}
21+
experimental-features = nix-command flakes
22+
allow-import-from-derivation = true
23+
substituters = https://cache.nixos.org https://cache.iog.io
24+
trusted-public-keys = hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ= cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
25+
26+
- name: Checkout repository
27+
uses: actions/checkout@v3
28+
29+
- name: Update flake.lock
30+
uses: DeterminateSystems/update-flake-lock@v19
31+
with:
32+
token: ${{ secrets.GITHUB_TOKEN }}
33+
inputs: hackageNix CHaP
34+
nix-options: --accept-flake-config
35+
pr-title: "flake.lock: update Hackage and CHaP"
36+
pr-labels: dependencies, automated
37+
pr-body: |
38+
Automated changes by the [update-flake-lock](https://github.com/DeterminateSystems/update-flake-lock) GitHub Action.
39+
40+
```
41+
{{ env.GIT_COMMIT_MESSAGE }}
42+
```

0 commit comments

Comments
 (0)