Skip to content

Commit

Permalink
PLF-4450 : Allow to display help even if there is a wrong setup
Browse files Browse the repository at this point in the history
  • Loading branch information
aheritier committed Apr 11, 2013
1 parent a023352 commit 8434cce
Showing 1 changed file with 19 additions and 19 deletions.
Expand Up @@ -33,25 +33,6 @@ if (System.properties['os.name'].toLowerCase().contains('windows')) {
scriptExtension = "bat" scriptExtension = "bat"
} }


if (!System.getProperty("catalina.home")) {
println 'error: Erroneous setup, system property catalina.home not defined.'
System.exit 1
}

catalinaHome = new File(System.getProperty("catalina.home"))

if (!catalinaHome.isDirectory()) {
println "error: Erroneous setup, platform home directory (${catalinaHome}) is invalid."
System.exit 1
}

extensionsDirectory = new File(catalinaHome, "extensions")

if (!extensionsDirectory.isDirectory()) {
println "error: Erroneous setup, extensions directory (${extensionsDirectory}) is invalid."
System.exit 1
}

def cli = new CliBuilder( def cli = new CliBuilder(
posix: false, posix: false,
stopAtNonOption: true, stopAtNonOption: true,
Expand Down Expand Up @@ -93,6 +74,25 @@ if (options.arguments()) {
System.exit 1 System.exit 1
} }


if (!System.getProperty("catalina.home")) {
println 'error: Erroneous setup, system property catalina.home not defined.'
System.exit 1
}

catalinaHome = new File(System.getProperty("catalina.home"))

if (!catalinaHome.isDirectory()) {
println "error: Erroneous setup, platform home directory (${catalinaHome}) is invalid."
System.exit 1
}

extensionsDirectory = new File(catalinaHome, "extensions")

if (!extensionsDirectory.isDirectory()) {
println "error: Erroneous setup, extensions directory (${extensionsDirectory}) is invalid."
System.exit 1
}

def listExtensions() { def listExtensions() {
println "" println ""
println "Available extensions:" println "Available extensions:"
Expand Down

0 comments on commit 8434cce

Please sign in to comment.