Skip to content

Commit

Permalink
Fix problems with snap release (#7239)
Browse files Browse the repository at this point in the history
Cherry-pick 2022464.
  • Loading branch information
damonbarry authored Mar 16, 2024
1 parent 42295cc commit 40e4fdd
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
5 changes: 2 additions & 3 deletions builds/misc/packages-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ stages:
- script: |
sudo snap install snapcraft --classic
lxd init --minimal
snapcraft --use-lxd
SNAPCRAFT_BUILD_INFO=1 snapcraft --use-lxd
displayName: Build snap
env:
SNAPCRAFT_BUILD_INFO: 1
Expand Down Expand Up @@ -378,8 +378,7 @@ stages:
sudo snap install snapcraft --classic
for pkg in $(ls $(System.ArtifactsDirectory)/**/*.snap)
do
# TODO: change release channel from 'edge' to 'stable'
snapcraft upload --release=edge "$pkg"
snapcraft upload --release=stable "$pkg"
done
logdir='$(Build.ArtifactStagingDirectory)/logs'
Expand Down
2 changes: 1 addition & 1 deletion builds/misc/templates/build-packages.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ stages:
- script: |
sudo snap install snapcraft --classic
lxd init --minimal
snapcraft --use-lxd
SNAPCRAFT_BUILD_INFO=1 snapcraft --use-lxd
displayName: Build snap
condition: eq(${{ parameters['E2EBuild'] }}, false)
- task: CopyFiles@2
Expand Down
2 changes: 1 addition & 1 deletion snap/snapcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ parts:
rm -rf $CRAFT_PART_BUILD/target
SC_VERSION="$(cat $CRAFT_PART_SRC/version.txt)"
craftctl set version="$SC_VERSION"
# if version contains substing "dev" set grade to devel, else stable
# if version contains substring "dev" set grade to devel, else stable
if test "${SC_VERSION#*dev}" != "$SC_VERSION" ; then
craftctl set grade=devel
else
Expand Down

0 comments on commit 40e4fdd

Please sign in to comment.