summaryrefslogtreecommitdiffstats
path: root/snap
diff options
context:
space:
mode:
author林博仁(Buo-ren Lin) <Buo.Ren.Lin@gmail.com>2019-04-12 00:55:02 +0800
committer林博仁(Buo-ren Lin) <Buo.Ren.Lin@gmail.com>2019-04-12 01:08:58 +0800
commit6fdf37ef8973fb7afbc90fafdfeb56cd1ff114b8 (patch)
tree30921693953dfe2ce4b9bc93fa113c2778e602cd /snap
parent15a9925d2ad7fdd068c4f52259c7e590435a7540 (diff)
snap: Incorporate selective-checkout to ensure a revision for stable channel is always available
Refer-to: Selective-checkout: Check out the tagged release revision if it isn't promoted to the stable channel - doc - snapcraft.io <https://forum.snapcraft.io/t/selective-checkout-check-out-the-tagged-release-revision-if-it-isnt-promoted-to-the-stable-channel/10617> Refer-to: Releasing your app - Documentation for snaps: Universal Linux packages <https://docs.snapcraft.io/releasing-your-app/6795> Signed-off-by: 林博仁(Buo-ren Lin) <Buo.Ren.Lin@gmail.com>
Diffstat (limited to 'snap')
-rw-r--r--snap/snapcraft.yaml13
1 files changed, 11 insertions, 2 deletions
diff --git a/snap/snapcraft.yaml b/snap/snapcraft.yaml
index 767833e3..cb7efbc2 100644
--- a/snap/snapcraft.yaml
+++ b/snap/snapcraft.yaml
@@ -43,6 +43,8 @@ plugs:
parts:
glances:
+ after:
+ - selective-checkout
plugin: python
source: .
# FIXME: Theoretically this also replaces `summary` and `description`
@@ -52,8 +54,7 @@ parts:
parse-info: [setup.py]
override-pull: |
snapcraftctl pull
- snapcraftctl set-version \
- "$(git describe --always --dirty --tags --match 'v*' | sed s/^v//)"
+ "$SNAPCRAFT_STAGE"/scriptlets/selective-checkout
bottle:
plugin: python
source: https://github.com/bottlepy/bottle.git
@@ -69,3 +70,11 @@ parts:
plugin: dump
organize:
'*': bin/
+ selective-checkout:
+ plugin: nil
+ build-packages:
+ - git
+ stage-snaps:
+ - selective-checkout
+ prime:
+ - -*