Skip to content

Commit ddb6af0

Browse files
committed
Upload and release build artifacts
1 parent 9cf25f9 commit ddb6af0

File tree

1 file changed

+19
-2
lines changed

1 file changed

+19
-2
lines changed

.github/workflows/build.yml

+19-2
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,16 @@ jobs:
4343
run: |
4444
stack --no-terminal build --only-dependencies --test --fast --system-ghc
4545
46-
- name: Build
46+
- name: Build and install
4747
run: |
48-
stack --no-terminal build --test --fast --system-ghc --no-run-tests
48+
stack --no-terminal build --test --fast --system-ghc --no-run-tests --copy-bins --local-bin-path=.
49+
50+
- name: Upload build artifact
51+
uses: actions/upload-artifact@v2
52+
with:
53+
name: plc-llvm
54+
path: './plc-llvm'
55+
if-no-files-found: error
4956

5057
- name: Run tests
5158
run: |
@@ -59,3 +66,13 @@ jobs:
5966
check_name: 'tests'
6067
comment_title: 'Test results'
6168
fail_on: 'test failures'
69+
70+
- name: Upload release
71+
if: ${{ github.ref == 'refs/heads/master' }}
72+
uses: svenstaro/upload-release-action@v2
73+
with:
74+
repo_token: ${{ secrets.GITHUB_TOKEN }}
75+
file: './plc-llvm'
76+
asset_name: 'plc-llvm'
77+
tag: 'latest-plc-llvm'
78+
overwrite: true

0 commit comments

Comments
 (0)