From 706ae974bc3ce8ac6319d5aedd8f8d791866b9bc Mon Sep 17 00:00:00 2001 From: idk Date: Sun, 30 Apr 2023 05:05:46 +0000 Subject: [PATCH] add download-back buildscript --- buildscripts/release-download.sh | 42 ++++++++++++++++++++++++++++++++ makefiles/su.mk | 1 + 2 files changed, 43 insertions(+) create mode 100755 buildscripts/release-download.sh diff --git a/buildscripts/release-download.sh b/buildscripts/release-download.sh new file mode 100755 index 0000000..a79ef02 --- /dev/null +++ b/buildscripts/release-download.sh @@ -0,0 +1,42 @@ +#! /usr/bin/env bash + +SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd -P)/.. +cd "$SCRIPT_DIR" || exit 1 + +. "$SCRIPT_DIR/i2pversion" + +if [ -f i2pversion_override ]; then + . "$SCRIPT_DIR/i2pversion_override" +fi + +mv "$SCRIPT_DIR/config_override.sh" "$SCRIPT_DIR/config_override.sh.bak" +. "$SCRIPT_DIR/config.sh" + +### How to set up this script: +# +# This script will not work unless you give it a Github API key. +# You need to create a file in your $HOME directory, which on +# Windows will by /c/Users/yourusername, called github-release-config.sh, +# containing this key as the variable GITHUB_TOKEN. +# github-release-config.sh must also contain: +# GITHUB_USERNAME=your github username + +. "$HOME/github-release-config.sh" + +if [ -f ./i2pversion_override ]; then + . ./i2pversion_override +fi + + + +echo github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "I2P-Easy-Install-Bundle-$I2P_VERSION.exe" -t "$I2P_VERSION" +github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "I2P-Easy-Install-Bundle-$I2P_VERSION.exe" -t "$I2P_VERSION" + +echo github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "I2P.zip" -t "$I2P_VERSION" +github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "I2P.zip" -t "$I2P_VERSION" + +echo github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "i2p.i2p.jpackage-build.tar.gz" -t "$I2P_VERSION" +github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "i2p.i2p.jpackage-build.tar.gz" -t "$I2P_VERSION" + +echo github-release download -u "$GITHUB_USERNAME" -r i2p -t "$I2P_VERSION" -n "./I2P-jpackage-windows-$I2P_VERSION.zip" +github-release download -u "$GITHUB_USERNAME" -r i2p -t "$I2P_VERSION" -n "./I2P-jpackage-windows-$I2P_VERSION.zip" diff --git a/makefiles/su.mk b/makefiles/su.mk index 50be0b7..245f049 100644 --- a/makefiles/su.mk +++ b/makefiles/su.mk @@ -10,6 +10,7 @@ prepupdate: cp -v "I2P-Easy-Install-Bundle-$(PROFILE_VERSION)-signed.su3" i2pwinupdate.su3 su3: $(GOPATH)/src/i2pgit.org/idk/su3-tools/su3-tools + cp -v "I2P-Easy-Install-Bundle-$(PROFILE_VERSION).exe" "I2P-Easy-Install-Bundle-$(PROFILE_VERSION)-signed.exe" $(GOPATH)/src/i2pgit.org/idk/su3-tools/su3-tools -name "I2P-Easy-Install-Bundle-$(PROFILE_VERSION)-signed" -signer "$(SIGNER)" -version "$(PROFILE_VERSION)" java -cp "$(HOME)/i2p/lib/*" net.i2p.crypto.SU3File sign -c ROUTER -f EXE I2P-Easy-Install-Bundle-$(PROFILE_VERSION)-signed.exe I2P-Easy-Install-Bundle-$(PROFILE_VERSION)-signed.su3 "$(HOME)/.i2p-plugin-keys/news-su3-keystore.ks" $(PROFILE_VERSION) $(SIGNER)