Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Improved: Add extra classpath directories for ofbiz.tar/zip
(OFBIZ-12136)

Allows people to add configuration files and jars (database drivers) when
using the binary distribution.

Thanks: Eugen Stan for improvement
  • Loading branch information
ieugen committed Jan 15, 2021
1 parent 7165768 commit cc76b99
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions build.gradle
Expand Up @@ -1106,3 +1106,15 @@ new File("${gradle.getGradleUserHomeDir().getAbsolutePath()}/daemon/${gradle.get
it.delete()
}
}

tasks.startScripts {
doLast {
// Alter the start script for Unix systems.
unixScript.text =
unixScript.text.replace('CLASSPATH=$APP_HOME/lib','CLASSPATH=$APP_HOME/config/:$APP_HOME/lib-extra/*:$APP_HOME/lib')
// Alter the start script for Windows systems.
windowsScript.text =
windowsScript.text.replace('CLASSPATH=%APP_HOME%\\lib',
'CLASSPATH=%APP_HOME%\\conf\\;%APP_HOME%\\lib-extra\\*;%APP_HOME%\\lib')
}
}

0 comments on commit cc76b99

Please sign in to comment.