Skip to content

Commit 07895dd

Browse files
committed
ci(release): Consolidate snapcraft setup into GoReleaser workflow
1 parent e889615 commit 07895dd

File tree

4 files changed

+26
-93
lines changed

4 files changed

+26
-93
lines changed

.github/workflows/release.yml

+9-1
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,13 @@ jobs:
4242
with:
4343
go-version: '1.23'
4444
cache: true
45+
46+
- name: Set up Snapcraft
47+
run: |
48+
sudo apt-get update
49+
sudo apt-get -yq --no-install-suggests --no-install-recommends install snapcraft
50+
mkdir -p $HOME/.cache/snapcraft/download
51+
mkdir -p $HOME/.cache/snapcraft/stage-packages
4552
4653
# Run GoReleaser
4754
- name: Run GoReleaser
@@ -52,4 +59,5 @@ jobs:
5259
args: release --clean
5360
env:
5461
# Used for GitHub token and pushing to other repos
55-
GITHUB_TOKEN: ${{ secrets.GH_PERSONAL_TOKEN }}
62+
GITHUB_TOKEN: ${{ secrets.GH_PERSONAL_TOKEN }}
63+
SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_LOGIN }}

.github/workflows/snap.yml

-64
This file was deleted.

.goreleaser.yml

+17-1
Original file line numberDiff line numberDiff line change
@@ -90,4 +90,20 @@ brews:
9090
test: |
9191
system "#{bin}/httpprobe", "version"
9292
93-
# Snapcraft is handled by external snapcraft.yaml in the snap directory
93+
snapcrafts:
94+
- id: httpprobe
95+
name: httpprobe
96+
publish: true
97+
name_template: "{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}"
98+
summary: A powerful HTTP API testing tool for defining, running, and validating API tests using YAML or JSON
99+
description: |
100+
httpprobe is a powerful HTTP API testing tool for defining, running, and validating API tests using YAML or JSON.
101+
grade: stable
102+
confinement: strict
103+
license: MIT
104+
base: core20
105+
apps:
106+
probe:
107+
command: httpprobe
108+
plugs: [ "home", "network" ]
109+
aliases: [ "httprobe" ]

snap/snapcraft.yaml

-27
This file was deleted.

0 commit comments

Comments
 (0)