From 012c5c6cb709c30c45c1c2a89499c2faa33e28b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= Date: Sun, 14 Jan 2024 07:55:25 +0000 Subject: [PATCH] With USER_PLUGINS_DIR we may install plugins in our home directory --- core/src/com/biglybt/platform/unix/startupScript | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/core/src/com/biglybt/platform/unix/startupScript b/core/src/com/biglybt/platform/unix/startupScript index 6fb4a59657f..f0092685bc5 100644 --- a/core/src/com/biglybt/platform/unix/startupScript +++ b/core/src/com/biglybt/platform/unix/startupScript @@ -4,6 +4,7 @@ AUTOUPDATE_SCRIPT=1 # change to 0 if you don't want your changes overwritten on next SCRIPT_VERSION change JAVA_PROGRAM_DIR="" # use full path to java bin dir, ex. "/usr/java/j2sdk1.4.2/bin/" #PROGRAM_DIR="/home/username/apps/biglybt" # use full path to BiglyBT bin dir +#USER_PLUGINS_DIR="$HOME/.biglybt" JAVA_PROPS="" ####################################### @@ -103,7 +104,7 @@ runJavaOutput() RESULT=`$JAVABIN \ -cp "${CLASSPATH}" \ "-Djava.library.path=${PROGRAM_DIR}" \ - "-Dazureus.install.path=${PROGRAM_DIR}" \ + "-Dazureus.install.path=${USER_PLUGINS_DIR}" \ "-Dazureus.script=$0" \ "-Dawt.useSystemAAFontSettings=gasp" \ ${JAVA_PROPS} \ @@ -190,6 +191,11 @@ elif [ ! -f "${PROGRAM_DIR}/BiglyBT.jar" ]; then exit 1 fi +# by default USER_PLUGINS_DIR is equal to PROGRAM DIR +if [ -z "$USER_PLUGINS_DIR" ]; then + USER_PLUGINS_DIR=${PROGRAM_DIR} +fi + OLDPATH=$PWD # Change path here so we can do for loop on program dirs with spaces @@ -229,7 +235,7 @@ echo "$MSG_LOADING" $JAVABIN -Xmx256m \ -cp "${CLASSPATH}" \ "-Djava.library.path=${PROGRAM_DIR}" \ - "-Dazureus.install.path=${PROGRAM_DIR}" \ + "-Dazureus.install.path=${USER_PLUGINS_DIR}" \ "-Dazureus.script=$0" \ ${JAVA_PROPS} \ ${JAVA_ARGS} \