Skip to content

Commit

Permalink
chore: publish artifacts on GitHub
Browse files Browse the repository at this point in the history
  • Loading branch information
michalrus committed Nov 26, 2024
1 parent fbeede9 commit 5363333
Show file tree
Hide file tree
Showing 2 changed files with 55 additions and 0 deletions.
54 changes: 54 additions & 0 deletions .github/workflows/upload.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
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 -x
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-*.* .
echo =================================================================
ls -alh
- uses: actions/upload-artifact@v4
with:
name: testgen-hs-aarch64-darwin.tar.bz2
path: testgen-hs-aarch64-darwin.tar.bz2
- uses: actions/upload-artifact@v4
with:
name: testgen-hs-x86_64-darwin.tar.bz2
path: testgen-hs-x86_64-darwin.tar.bz2
- uses: actions/upload-artifact@v4
with:
name: testgen-hs-x86_64-linux.tar.bz2
path: testgen-hs-x86_64-linux.tar.bz2
- uses: actions/upload-artifact@v4
with:
name: testgen-hs-x86_64-windows.zip
path: testgen-hs-x86_64-windows.zip



- name: Upload Artifacts
run: |
set -x
for f in testgen-hs-*.* ; do
gh actions upload-artifact --name "$f" --path "$f"
done
1 change: 1 addition & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@
programs.ormolu.enable = true; # Haskell
programs.cabal-fmt.enable = true;
programs.shfmt.enable = true;
programs.yamlfmt.enable = true;
};
};

Expand Down

0 comments on commit 5363333

Please sign in to comment.