Skip to content

Commit 2473068

Browse files
committed
Attempt to use the latest snapcraft build
1 parent 6183350 commit 2473068

File tree

2 files changed

+25
-7
lines changed

2 files changed

+25
-7
lines changed

scripts/bump-version.sh

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ else
2727
echo "version.go updated"
2828
fi
2929

30-
version=$version ./yq -i '.version=strenv(version)' snap/snapcraft.yaml
30+
version=$version ./yq -i '.version=strenv(version) | .parts.yq.source-tag=strenv(version)' snap/snapcraft.yaml
3131

3232
actualSnapVersion=$(./yq '.version' snap/snapcraft.yaml)
3333

@@ -38,6 +38,15 @@ else
3838
echo "snapcraft updated"
3939
fi
4040

41+
actualSnapVersion=$(./yq '.parts.yq.source-tag' snap/snapcraft.yaml)
42+
43+
if [ "$actualSnapVersion" != "$version" ]; then
44+
echo "Failed to update snapcraft"
45+
exit 1
46+
else
47+
echo "snapcraft updated"
48+
fi
49+
4150
git add cmd/version.go snap/snapcraft.yaml
4251
git commit -m 'Bumping version'
4352
git tag $version

snap/snapcraft.yaml

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,26 @@ version: 'v4.40.5'
33
summary: A lightweight and portable command-line data file processor
44
description: |
55
`yq` uses [jq](https://github.com/stedolan/jq) like syntax but works with yaml, json, xml, csv, properties and TOML files.
6-
base: core18
6+
base: core22
77
grade: stable # devel|stable. must be 'stable' to release into candidate/stable channels
88
confinement: strict
9+
10+
architectures:
11+
- build-on: s390x
12+
- build-on: ppc64el
13+
- build-on: arm64
14+
- build-on: armhf
15+
- build-on: amd64
16+
- build-on: i386
17+
918
apps:
1019
yq:
11-
command: yq
20+
command: bin/yq
1221
plugs: [home, removable-media]
1322
parts:
1423
yq:
1524
plugin: go
16-
go-channel: 1.20/stable
17-
source: .
18-
source-type: git
19-
go-importpath: github.com/mikefarah/yq
25+
source: https://github.com/mikefarah/yq.git
26+
source-tag: v4.40.5
27+
build-snaps:
28+
- go/latest/stable

0 commit comments

Comments
 (0)