Revert "Move bisq-* scripts from root directory to scripts directory"

This commit is contained in:
Alejandro García 2023-07-12 13:53:13 +00:00 committed by GitHub
parent ca86bbdb83
commit e5aef09e96
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 12 additions and 14 deletions

2
.gitignore vendored
View File

@ -23,9 +23,7 @@ build
*.~ava *.~ava
/bundles /bundles
/bisq-* /bisq-*
/scripts/bisq-*
/lib /lib
/scripts/lib
/xchange /xchange
desktop.ini desktop.ini
*/target/* */target/*

View File

@ -190,7 +190,7 @@ bitcoind: .localnet
-blocknotify='.localnet/bitcoind/blocknotify %s' -blocknotify='.localnet/bitcoind/blocknotify %s'
seednode: seednode/build seednode: seednode/build
./scripts/bisq-seednode \ ./bisq-seednode \
--baseCurrencyNetwork=BTC_REGTEST \ --baseCurrencyNetwork=BTC_REGTEST \
--useLocalhostForP2P=true \ --useLocalhostForP2P=true \
--useDevPrivilegeKeys=true \ --useDevPrivilegeKeys=true \
@ -203,7 +203,7 @@ seednode: seednode/build
--appName=seednode --appName=seednode
seednode2: seednode/build seednode2: seednode/build
./scripts/bisq-seednode \ ./bisq-seednode \
--baseCurrencyNetwork=BTC_REGTEST \ --baseCurrencyNetwork=BTC_REGTEST \
--useLocalhostForP2P=true \ --useLocalhostForP2P=true \
--useDevPrivilegeKeys=true \ --useDevPrivilegeKeys=true \
@ -216,7 +216,7 @@ seednode2: seednode/build
--appName=seednode2 --appName=seednode2
mediator: desktop/build mediator: desktop/build
./scripts/bisq-desktop \ ./bisq-desktop \
--baseCurrencyNetwork=BTC_REGTEST \ --baseCurrencyNetwork=BTC_REGTEST \
--useLocalhostForP2P=true \ --useLocalhostForP2P=true \
--useDevPrivilegeKeys=true \ --useDevPrivilegeKeys=true \
@ -225,7 +225,7 @@ mediator: desktop/build
--appName=Mediator --appName=Mediator
alice: setup alice: setup
./scripts/bisq-desktop \ ./bisq-desktop \
--baseCurrencyNetwork=BTC_REGTEST \ --baseCurrencyNetwork=BTC_REGTEST \
--useLocalhostForP2P=true \ --useLocalhostForP2P=true \
--useDevPrivilegeKeys=true \ --useDevPrivilegeKeys=true \
@ -240,7 +240,7 @@ alice: setup
--appName=Alice --appName=Alice
bob: setup bob: setup
./scripts/bisq-desktop \ ./bisq-desktop \
--baseCurrencyNetwork=BTC_REGTEST \ --baseCurrencyNetwork=BTC_REGTEST \
--useLocalhostForP2P=true \ --useLocalhostForP2P=true \
--useDevPrivilegeKeys=true \ --useDevPrivilegeKeys=true \

View File

@ -17,7 +17,7 @@ configure(rootProject) {
// remove the 'bisq-*' scripts and 'lib' dir generated by the 'installDist' task // remove the 'bisq-*' scripts and 'lib' dir generated by the 'installDist' task
task clean { task clean {
doLast { doLast {
delete fileTree(dir: "$rootProject.projectDir/scripts", include: 'bisq-*'), "$rootProject.projectDir/scripts/lib" delete fileTree(dir: rootProject.projectDir, include: 'bisq-*'), 'lib'
} }
} }
} }
@ -59,27 +59,27 @@ configure([project(':cli'),
copy { copy {
from "$destinationDir/bin" from "$destinationDir/bin"
into "$rootProject.projectDir/scripts" into rootProject.projectDir
} }
// copy libs required for generated shell script classpaths to 'lib' dir under // copy libs required for generated shell script classpaths to 'lib' dir under
// the project root directory // the project root directory
copy { copy {
from "$destinationDir/lib" from "$destinationDir/lib"
into "${rootProject.projectDir}/scripts/lib" into "${rootProject.projectDir}/lib"
} }
// edit generated shell scripts such that they expect to be executed in the // edit generated shell scripts such that they expect to be executed in the
// project root dir as opposed to a 'bin' subdirectory // project root dir as opposed to a 'bin' subdirectory
def windowsScriptFile = file("${rootProject.projectDir}/scripts/bisq-${applicationName}.bat") def windowsScriptFile = file("${rootProject.projectDir}/bisq-${applicationName}.bat")
windowsScriptFile.text = windowsScriptFile.text.replace( windowsScriptFile.text = windowsScriptFile.text.replace(
'set APP_HOME=%DIRNAME%..', 'set APP_HOME=%DIRNAME%') 'set APP_HOME=%DIRNAME%..', 'set APP_HOME=%DIRNAME%')
def unixScriptFile = file("${rootProject.projectDir}/scripts/bisq-$applicationName") def unixScriptFile = file("${rootProject.projectDir}/bisq-$applicationName")
unixScriptFile.text = unixScriptFile.text.replace( unixScriptFile.text = unixScriptFile.text.replace(
'APP_HOME=$( cd "${APP_HOME:-./}.." && pwd -P ) || exit', 'APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit') 'APP_HOME=$( cd "${APP_HOME:-./}.." && pwd -P ) || exit', 'APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit')
if (applicationName == 'desktop') { if (applicationName == 'desktop') {
def script = file("${rootProject.projectDir}/scripts/bisq-$applicationName") def script = file("${rootProject.projectDir}/bisq-$applicationName")
script.text = script.text.replace( script.text = script.text.replace(
'DEFAULT_JVM_OPTS=""', 'DEFAULT_JVM_OPTS="-XX:MaxRAM=8g -Xss1280k -XX:+UseG1GC ' + 'DEFAULT_JVM_OPTS=""', 'DEFAULT_JVM_OPTS="-XX:MaxRAM=8g -Xss1280k -XX:+UseG1GC ' +
'-XX:MaxHeapFreeRatio=10 -XX:MinHeapFreeRatio=5 -XX:+UseStringDeduplication ' + '-XX:MaxHeapFreeRatio=10 -XX:MinHeapFreeRatio=5 -XX:+UseStringDeduplication ' +
@ -90,7 +90,7 @@ configure([project(':cli'),
// Pass the logback config file as a system property to avoid chatty // Pass the logback config file as a system property to avoid chatty
// logback startup due to multiple logback.xml files in the classpath // logback startup due to multiple logback.xml files in the classpath
// (:daemon & :cli). // (:daemon & :cli).
def script = file("${rootProject.projectDir}/scripts/bisq-$applicationName") def script = file("${rootProject.projectDir}/bisq-$applicationName")
script.text = script.text.replace( script.text = script.text.replace(
'DEFAULT_JVM_OPTS=""', 'DEFAULT_JVM_OPTS="' + 'DEFAULT_JVM_OPTS=""', 'DEFAULT_JVM_OPTS="' +
'-Dlogback.configurationFile=apitest/build/resources/main/logback.xml"') '-Dlogback.configurationFile=apitest/build/resources/main/logback.xml"')