snap: fix grade-setting

> variable 'grade' can be set only once.

Signed-off-by: Michał Sawicz <michal@sawicz.net>
This commit is contained in:
Michał Sawicz 2024-02-27 00:54:39 +01:00 committed by Dirk Hohndel
parent bf5510e5a6
commit c3aa505f2b

View file

@ -159,12 +159,13 @@ parts:
- qttools5-dev
override-pull: |
craftctl default
craftctl set grade=devel
if [ ! -f latest-subsurface-buildnumber ]; then
git fetch --depth=1 https://github.com/subsurface/nightly-builds.git branch-for-$( git rev-parse HEAD )
git checkout FETCH_HEAD latest-subsurface-buildnumber
# We succeeded getting the release version, allow publishing above `beta`
craftctl set grade=stable
else
craftctl set grade=devel
fi
craftctl set version=$( scripts/get-version )
override-build: |