-
Notifications
You must be signed in to change notification settings - Fork 0
57 lines (57 loc) · 2.48 KB
/
upload.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
57
name: Upload Artifacts
on:
push:
env:
GH_TOKEN: ${{ github.token }}
jobs:
hydra-build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
with:
extra-conf: |
substituters = https://cache.nixos.org https://cache.iog.io
trusted-public-keys = cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY= hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ=
- name: Wait for Hydra
timeout-minutes: 60
uses: input-output-hk/actions/wait-for-hydra@latest
with:
check: "ci/hydra-build:required"
- name: Download Artifacts from Hydra
run: |
set -euo pipefail
nix build --builders "" --max-jobs 0 .#hydraJobs.testgen-hs.x86_64-linux && cp result/testgen-hs-*.* .
nix build --builders "" --max-jobs 0 .#hydraJobs.testgen-hs.x86_64-windows && cp result/testgen-hs-*.* .
nix build --builders "" --max-jobs 0 .#hydraJobs.testgen-hs.x86_64-darwin && cp result/testgen-hs-*.* .
nix build --builders "" --max-jobs 0 .#hydraJobs.testgen-hs.aarch64-darwin && cp result/testgen-hs-*.* .
- name: Read Version
run: |
set -euo pipefail
version=$(nix eval --json .#packages.x86_64-linux.default.version | jq -r .)
echo "Version is $version"
echo "version=$version" >> $GITHUB_ENV
- name: Upload Artifact (aarch64-darwin)
uses: actions/upload-artifact@v4
with:
name: testgen-hs-${{ env.version }}-aarch64-darwin.tar.bz2
path: testgen-hs-${{ env.version }}-aarch64-darwin.tar.bz2
if-no-files-found: error
- name: Upload Artifact (x86_64-darwin)
uses: actions/upload-artifact@v4
with:
name: testgen-hs-${{ env.version }}-x86_64-darwin.tar.bz2
path: testgen-hs-${{ env.version }}-x86_64-darwin.tar.bz2
if-no-files-found: error
- name: Upload Artifact (x86_64-linux)
uses: actions/upload-artifact@v4
with:
name: testgen-hs-${{ env.version }}-x86_64-linux.tar.bz2
path: testgen-hs-${{ env.version }}-x86_64-linux.tar.bz2
if-no-files-found: error
- name: Upload Artifact (x86_64-windows)
uses: actions/upload-artifact@v4
with:
name: testgen-hs-${{ env.version }}-x86_64-windows.zip
path: testgen-hs-${{ env.version }}-x86_64-windows.zip
if-no-files-found: error