From ea743ef6b48dcd37187bf91b66fcffcbf2915ea8 Mon Sep 17 00:00:00 2001 From: Bill Mahoney Date: Wed, 9 Sep 2020 15:20:11 -0700 Subject: [PATCH] fix: local snap development Signed-off-by: Bill Mahoney --- .gitignore | 1 + VERSION | 1 - snap/snapcraft.yaml | 7 ++++++- 3 files changed, 7 insertions(+), 2 deletions(-) delete mode 100644 VERSION diff --git a/.gitignore b/.gitignore index 94c3566..842b6c0 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ *.snap prime/ squashfs-root/ +VERSION diff --git a/VERSION b/VERSION deleted file mode 100644 index 6085e94..0000000 --- a/VERSION +++ /dev/null @@ -1 +0,0 @@ -1.2.1 diff --git a/snap/snapcraft.yaml b/snap/snapcraft.yaml index aef59c2..5c46338 100644 --- a/snap/snapcraft.yaml +++ b/snap/snapcraft.yaml @@ -2,7 +2,12 @@ name: edgex-device-grove base: core18 version: "replace-me" version-script: | - echo $(cat VERSION)-$(date +%Y%m%d)+$(git rev-parse --short HEAD) + if [ -f VERSION ]; then + PROJECT_VERSION=$(cat VERSION) + else + PROJECT_VERSION=local-dev + fi + echo $PROJECT_VERSION-$(date +%Y%m%d)+$(git rev-parse --short HEAD) summary: Connect to Grove sensors on Raspberry Pi with EdgeX description: | The EdgeX Device Grove Service is developed to control/communicate Grove