Skip to content

Commit b6790d6

Browse files
authored
fix: inject snap package version from git tag (#50)
Fixes #49
1 parent 2b88fca commit b6790d6

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -188,6 +188,13 @@ jobs:
188188
ref: ${{ env.TAG }}
189189
fetch-depth: 0
190190

191+
- name: Set snap version from tag
192+
run: |
193+
VERSION="${TAG#v}"
194+
sed -i "s/^version: git$/version: '${VERSION}'/" snap/snapcraft.yaml
195+
echo "Snap version: ${VERSION}"
196+
grep '^version:' snap/snapcraft.yaml
197+
191198
- name: Build snap
192199
uses: snapcore/action-build@v1
193200
id: build

0 commit comments

Comments
 (0)