package.bash: Encode host distribution into tar filename
This commit is contained in:
parent
ecdc58baa3
commit
b3c9a275c7
3
.gitignore
vendored
3
.gitignore
vendored
@ -4,8 +4,9 @@
|
|||||||
# temporary files created by the tests
|
# temporary files created by the tests
|
||||||
/tmp
|
/tmp
|
||||||
|
|
||||||
# binary releases
|
# binary releases and signatiures
|
||||||
/*.tar.gz
|
/*.tar.gz
|
||||||
|
/*.asc
|
||||||
|
|
||||||
# Binaries created for cpu profiling
|
# Binaries created for cpu profiling
|
||||||
*.test
|
*.test
|
||||||
|
14
package.bash
14
package.bash
@ -1,12 +1,14 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
set -eux
|
set -eu
|
||||||
|
|
||||||
source build.bash
|
source build.bash # Builds binary and sets GITVERSION (example: v0.7-15-gf01f599)
|
||||||
|
source /etc/os-release # Sets ID (example: fedora) and VERSION_ID (example: 23)
|
||||||
|
ARCH=$(go env GOARCH)
|
||||||
|
|
||||||
ARCH=$(go version | cut -d ' ' -f 4 | tr / -)
|
TARGZ=gocryptfs_${GITVERSION}_${ID}${VERSION_ID}_${ARCH}.tar.gz
|
||||||
|
|
||||||
TARGZ=gocryptfs_${GITVERSION}_$ARCH.tar.gz
|
|
||||||
|
|
||||||
tar czf $TARGZ gocryptfs
|
tar czf $TARGZ gocryptfs
|
||||||
ls -lh $TARGZ
|
|
||||||
|
echo "Tar created."
|
||||||
|
echo "Hint for signing: gpg -u 23A02740 --armor --detach-sig $TARGZ"
|
||||||
|
Loading…
Reference in New Issue
Block a user