From 2db71e402d48ead52e0c04f7a3ad5c0fdc987f76 Mon Sep 17 00:00:00 2001 From: idk Date: Sun, 6 Nov 2022 21:09:40 -0500 Subject: [PATCH] move fixperms to own script --- fixperms.sh | 6 ++++++ getprebuilt.sh | 11 ++++++----- 2 files changed, 12 insertions(+), 5 deletions(-) create mode 100755 fixperms.sh diff --git a/fixperms.sh b/fixperms.sh new file mode 100755 index 0000000..eb6d21c --- /dev/null +++ b/fixperms.sh @@ -0,0 +1,6 @@ +#! /usr/bin/env sh + +find I2P -type d -exec chmod -v 755 {} \; +find I2P -type f -exec chmod -v +rw {} \; +find I2P -type d -exec chmod -v 755 {} \; +find I2P -type f -exec chmod -v +rw {} \; \ No newline at end of file diff --git a/getprebuilt.sh b/getprebuilt.sh index 75fd0b2..9518135 100755 --- a/getprebuilt.sh +++ b/getprebuilt.sh @@ -22,9 +22,10 @@ if [ -z $TODAYSDATE ]; then TODAYSDATE=$(date -d '-1 day' '+%Y%m%d') fi -echo github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "I2P.zip" -t "$TODAYSDATE" -github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "I2P.zip" -t "$TODAYSDATE" +if [ ! -f I2P.zip ]; then + echo github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "I2P.zip" -t "$TODAYSDATE" + github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "I2P.zip" -t "$TODAYSDATE" +fi unzip I2P.zip -sleep 1 -find I2P -type d -exec chmod 755 {} \; -find I2P -type f -exec chmod +rw {} \; \ No newline at end of file +sleep 3 +./fixperms.sh \ No newline at end of file