Skip to content

Commit 1bbdaf6

Browse files
authored
ci: download artifacts to release directory (ggml-org#6612)
When action download-artifact was updated to v4, the default download path changed. This fix binaries not being uploaded to releases.
1 parent f4183af commit 1bbdaf6

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

.github/workflows/build.yml

+8-2
Original file line numberDiff line numberDiff line change
@@ -938,6 +938,12 @@ jobs:
938938
- name: Download artifacts
939939
id: download-artifact
940940
uses: actions/download-artifact@v4
941+
with:
942+
path: ./artifact
943+
944+
- name: Move artifacts
945+
id: move_artifacts
946+
run: mkdir -p ./artifact/release && mv ./artifact/*/*.zip ./artifact/release
941947

942948
- name: Create release
943949
id: create_release
@@ -956,15 +962,15 @@ jobs:
956962
const path = require('path');
957963
const fs = require('fs');
958964
const release_id = '${{ steps.create_release.outputs.id }}';
959-
for (let file of await fs.readdirSync('./artifact')) {
965+
for (let file of await fs.readdirSync('./artifact/release')) {
960966
if (path.extname(file) === '.zip') {
961967
console.log('uploadReleaseAsset', file);
962968
await github.repos.uploadReleaseAsset({
963969
owner: context.repo.owner,
964970
repo: context.repo.repo,
965971
release_id: release_id,
966972
name: file,
967-
data: await fs.readFileSync(`./artifact/${file}`)
973+
data: await fs.readFileSync(`./artifact/release/${file}`)
968974
});
969975
}
970976
}

0 commit comments

Comments
 (0)