Skip to content

Commit e61a14b

Browse files
JohnMcLearclaude
andcommitted
fix(snap): use basename for the artifact path so publish-edge finds it
Snap publish-edge failed with "'release/etherpad-desktop_0.2.0_amd64.snap' is not a valid file" because actions/upload-artifact flattens path patterns into the artifact root. The build job uploads `release/*.snap`, which means the artifact's root contains the .snap file directly. When publish-edge downloads the artifact, the file lands at the workspace root — not under release/. Output the BASENAME only from the find step, so the path is valid in both the build context (where the file is at release/<name>.snap) and the publish context (where it's at <name>.snap after download). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 3af29bb commit e61a14b

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

.github/workflows/snap-publish.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,9 +70,15 @@ jobs:
7070

7171
- name: Locate snap file
7272
id: find
73+
# Output the BASENAME, not release/<name>.snap. actions/upload-artifact
74+
# flattens release/*.snap into the artifact root, so when publish-edge
75+
# downloads it the file lands at the workspace root — `release/` doesn't
76+
# exist there. Using just the basename keeps the same path valid in
77+
# both the build job (after `cd release` is implicit) and the publish
78+
# job (after artifact download).
7379
run: |
7480
file=$(ls release/*.snap | head -n1)
75-
echo "path=$file" >> "$GITHUB_OUTPUT"
81+
echo "path=$(basename "$file")" >> "$GITHUB_OUTPUT"
7682
7783
- name: Upload snap artifact
7884
uses: actions/upload-artifact@v4

0 commit comments

Comments
 (0)