set permissions for the executable after downloading it

This commit is contained in:
Pierre-Louis Bonicoli 2022-03-06 05:39:34 +01:00
parent aed354c99a
commit e929d49715
Signed by: pilou
GPG Key ID: 06914C4A5EDAA6DD

View File

@ -26,6 +26,8 @@ function download() {
find $BINDIR -type f -name gitea-$VERSION-linux-amd64.sha256 -exec sha256sum {} \; | sha256sum
gpg --keyserver keys.openpgp.org --recv 7C9E68152594688862D62AF62D9AE806EC1592E2
gpg --verify $BINDIR/gitea-$VERSION-linux-amd64.asc $BINDIR/gitea-$VERSION-linux-amd64
chmod u+x $BINDIR/gitea-$VERSION-linux-amd64
chown gitea.gitea $BINDIR/gitea-$VERSION-linux-amd64
set +x
}
@ -43,8 +45,6 @@ function backup() {
function upgrade() {
set -ex
chmod u+x $BINDIR/gitea-$VERSION-linux-amd64
chown gitea.gitea $BINDIR/gitea-$VERSION-linux-amd64
ln --force $BINDIR/gitea-$VERSION-linux-amd64 $BINDIR/gitea
set +x
}