[SKIP CI] Update snap
Maybe this one would be better :)
This commit is contained in:
parent
3640b82376
commit
6912a08652
2 changed files with 40 additions and 30 deletions
40
snap/snapcraft.yaml
Normal file
40
snap/snapcraft.yaml
Normal file
|
@ -0,0 +1,40 @@
|
|||
# You may ask yourself, why make a snap?
|
||||
# why not?
|
||||
|
||||
name: awl
|
||||
base: core20
|
||||
adopt-info: awl
|
||||
license: BSD-3-Clause
|
||||
summary: A command-line DNS query tool.
|
||||
description: |
|
||||
awl is a command line DNS tool, much like dig and drill.
|
||||
|
||||
grade: devel
|
||||
confinement: strict
|
||||
|
||||
architectures:
|
||||
- build-on: amd64
|
||||
- build-on: arm64
|
||||
- build-on: s390x
|
||||
- build-on: ppc64el
|
||||
- build-on: armhf
|
||||
|
||||
parts:
|
||||
awl:
|
||||
build-packages:
|
||||
- scdoc
|
||||
plugin: go
|
||||
source-type: git
|
||||
source: https://git.froth.zone/sam/awl
|
||||
override-pull: |
|
||||
snapcraftctl pull
|
||||
snapcraftctl set-version "$(git describe --always | sed 's/\([^-]*-g\)/r\1/;s/-/./g' || echo 'UNKNOWN')"
|
||||
override-build: |
|
||||
HASH=$(git describe --always | sed 's/\([^-]*-g\)/r\1/;s/-/./g' || echo 'UNKNOWN')+snap make
|
||||
PREFIX=$SNAPCRAFT_PART_INSTALL make install
|
||||
|
||||
apps:
|
||||
awl:
|
||||
command: bin/awl
|
||||
plugs:
|
||||
- network
|
|
@ -1,30 +0,0 @@
|
|||
# You might ask, why make a snap?
|
||||
# why not?
|
||||
|
||||
name: awl
|
||||
base: core20
|
||||
version: '0.1'
|
||||
summary: A command-line DNS query tool.
|
||||
description: |
|
||||
awl is a command line DNS tool, much like dig and drill.
|
||||
|
||||
grade: devel
|
||||
confinement: strict
|
||||
|
||||
apps:
|
||||
awl:
|
||||
command: bin/awl
|
||||
plugs:
|
||||
- network
|
||||
|
||||
parts:
|
||||
awl:
|
||||
plugin: go
|
||||
source-type: git
|
||||
source: https://git.froth.zone/sam/awl
|
||||
override-build: |
|
||||
# For some reason it's always dirty???
|
||||
go build -ldflags="-s -w -X=main.version=$(git describe --always | sed 's/\([^-]*-g\)/r\1/;s/-/./g' || echo 'UNKNOWN')+snap" -trimpath -o awl
|
||||
install -d $SNAPCRAFT_PART_INSTALL/bin
|
||||
cp -av awl $SNAPCRAFT_PART_INSTALL/bin/
|
||||
ls -l $SNAPCRAFT_PART_INSTALL/bin/awl
|
Loading…
Reference in a new issue