8000 archiving artifacts · codefriar/alpaca.cpp@564b861 · GitHub
[go: up one dir, main page]

Skip to content

Commit 564b861

Browse files
committed
archiving artifacts
1 parent 3f7d187 commit 564b861

File tree

1 file changed

+32
-56
lines changed

1 file changed

+32
-56
lines changed

.github/workflows/build.yml

Lines changed: 32 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -36,37 +36,13 @@ jobs:
3636
run: |
3737
make
3838
39-
- name: Set commit hash variables
40-
id: commit
41-
if: ${{ ( github.event_name == 'push' && github.ref == 'refs/heads/master' ) || github.event.inputs.create_release == 'true' }}
42-
uses: pr-mpt/actions-commit-hash@v2
43-
44-
- name: Pack artifacts
45-
id: pack_artifacts
46-
if: ${{ ( github.event_name == 'push' && github.ref == 'refs/heads/master' ) || github.event.inputs.create_release == 'true' }}
47-
run: |
48-
zip alpaca-${{ env.BRANCH_NAME }}-${{ steps.commit.outputs.short }}-bin-linux-x64.zip chat
49-
50-
- name: Create release
51-
id: create_release
52-
if: ${{ ( github.event_name == 'push' && github.ref == 'refs/heads/master' ) || github.event.inputs.create_release == 'true' }}
53-
uses: zendesk/action-create-release@v1
54-
env:
55-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
39+
- name: Archive production artifacts
40+
uses: actions/upload-artifact@v3
5641
with:
57-
tag_name: ${{ env.BRANCH_NAME }}-${{ steps.commit.outputs.short }}
42+
name: ubuntu
43+
path: |
44+
chat
5845
59-
- name: Upload release
60-
id: upload_release
61-
if: ${{ ( github.event_name == 'push' && github.ref == 'refs/heads/master' ) || github.event.inputs.create_release == 'true' }}
62-
uses: actions/upload-release-asset@v1
63-
env:
64-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
65-
with:
66-
upload_url: ${{ steps.create_release.outputs.upload_url }}
67-
asset_path: .\alpaca-${{ env.BRANCH_NAME }}-${{ steps.commit.outputs.short }}-bin-linux-x64.zip
68-
asset_name: alpaca-${{ env.BRANCH_NAME }}-${{ steps.commit.outputs.short }}-bin-linux-x64.zip
69-
asset_content_type: application/octet-stream
7046
7147
macOS-latest:
7248
runs-on: macOS-latest
@@ -86,37 +62,37 @@ jobs:
8662
run: |
8763
make
8864
89-
- name: Set commit hash variables
90-
id: commit
91-
if: ${{ ( github.event_name == 'push' && github.ref == 'refs/heads/master' ) || github.event.inputs.create_release == 'true' }}
92-
uses: pr-mpt/actions-commit-hash@v2
65+
- name: Archive production artifacts
66+
uses: actions/upload-artifact@v3
67+
with:
68+
name: macos
69+
path: |
70+
chat
9371
94-
- name: Pack artifacts
95-
id: pack_artifacts
96-
if: ${{ ( github.event_name == 'push' && github.ref == 'refs/heads/master' ) || github.event.inputs.create_release == 'true' }}
72+
macOS-arm64:
73+
runs-on: macOS-arm64
74+
75+
steps:
76+
- name: Clone
77+
id: checkout
78+
uses: actions/checkout@v1
79+
80+
- name: Dependencies
81+
id: depends
9782
run: |
98-
zip alpaca-${{ env.BRANCH_NAME }}-${{ steps.commit.outputs.short }}-bin-mac-x64.zip chat
99-
100-
- name: Create release
101-
id: create_release
102-
if: ${{ ( github.event_name == 'push' && github.ref == 'refs/heads/master' ) || github.event.inputs.create_release == 'true' }}
103-
uses: zendesk/action-create-release@v1
104-
env:
105-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
106-
with:
107-
tag_name: ${{ env.BRANCH_NAME }}-${{ steps.commit.outputs.short }}
83+
brew update
10884
109-
- name: Upload release
110-
id: upload_release
111-
if: ${{ ( github.event_name == 'push' && github.ref == 'refs/heads/master' ) || github.event.inputs.create_release == 'true' }}
112-
uses: actions/upload-release-asset@v1
113-
env:
114-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
85+
- name: Build
86+
id: make_build
87+
run: |
88+
make
89+
90+
- name: Archive production artifacts
91+
uses: actions/upload-artifact@v3
11592
with:
116-
upload_url: ${{ steps.create_release.outputs.upload_url }}
117-
asset_path: .\alpaca-${{ env.BRANCH_NAME }}-${{ steps.commit.outputs.short }}-bin-mac-x64.zip
118-
asset_name: alpaca-${{ env.BRANCH_NAME }}-${{ steps.commit.outputs.short }}-bin-mac-x64.zip
119-
asset_content_type: application/octet-stream
93+
name: macos
94+
path: |
95+
chat
12096
12197
windows-latest:
12298
runs-on: windows-latest

0 commit comments

Comments
 (0)
0