1
0
mirror of https://github.com/deadc0de6/dotdrop.git synced 2026-02-04 15:39:43 +00:00

dynamic resolve version in snapcraft

This commit is contained in:
deadc0de6
2020-10-24 23:40:18 +02:00
parent 7e1d2ba351
commit e4b6181a63

View File

@@ -1,6 +1,5 @@
name: dotdrop
version: latest
version-script: cat $SNAPCRAFT_STAGE/bin/dotdrop | grep '__requires__' | sed "s/.*'dotdrop==\(.*\)'/\1/"
adopt-info: version
summary: Save your dotfiles once, deploy them everywhere
description: |
Dotdrop makes the management of dotfiles between different hosts easy.
@@ -35,3 +34,9 @@ parts:
source: ../../
stage-packages:
- file
version:
source: .
plugin: nil
override-build: |
VERSION=$(git tag -l | tail -1 | sed 's/^v//g')
snapcraftctl set-version "${VERSION}"