Skip to content

Commit

Permalink
build: make asc use config.sh
Browse files Browse the repository at this point in the history
Similarly to mkdeb.sh.

Relates to netblue30#5140.
  • Loading branch information
kmk3 committed Jul 24, 2023
1 parent 872cc55 commit 86455eb
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 8 deletions.
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -339,8 +339,8 @@ dist: clean config.mk
rm -fr $(TARNAME)-$(VERSION)

.PHONY: asc
asc: config.mk
./mkasc.sh $(VERSION)
asc: config.sh
./mkasc.sh

.PHONY: deb
deb: dist config.sh
Expand Down
14 changes: 8 additions & 6 deletions mkasc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,13 @@
# Copyright (C) 2014-2023 Firejail Authors
# License GPL v2

echo "Calculating SHA256 for all files in /transfer - firejail version $1"
. "$(dirname "$0")/config.sh"

printf 'Calculating SHA256 for all files in /transfer - %s version %s' "$TARNAME" "$VERSION"

cd /transfer || exit 1
sha256sum ./* > "firejail-$1-unsigned"
gpg --clearsign --digest-algo SHA256 < "firejail-$1-unsigned" > "firejail-$1.asc"
gpg --verify "firejail-$1.asc"
gpg --detach-sign --armor "firejail-$1.tar.xz"
rm "firejail-$1-unsigned"
sha256sum ./* > "$TARNAME-$VERSION-unsigned"
gpg --clearsign --digest-algo SHA256 < "$TARNAME-$VERSION-unsigned" > "$TARNAME-$VERSION.asc"
gpg --verify "$TARNAME-$VERSION.asc"
gpg --detach-sign --armor "$TARNAME-$VERSION.tar.xz"
rm "$TARNAME-$VERSION-unsigned"

0 comments on commit 86455eb

Please sign in to comment.