groovy-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pa...@apache.org
Subject groovy git commit: GROOVY-8569 minor tweak (align version short flag with previous Groovy versions)
Date Fri, 18 May 2018 23:33:50 GMT
Repository: groovy
Updated Branches:
  refs/heads/master f37ca2092 -> 7d4cd7922


GROOVY-8569 minor tweak (align version short flag with previous Groovy versions)


Project: http://git-wip-us.apache.org/repos/asf/groovy/repo
Commit: http://git-wip-us.apache.org/repos/asf/groovy/commit/7d4cd792
Tree: http://git-wip-us.apache.org/repos/asf/groovy/tree/7d4cd792
Diff: http://git-wip-us.apache.org/repos/asf/groovy/diff/7d4cd792

Branch: refs/heads/master
Commit: 7d4cd792225fe60dbe0d0354ad52b29a5ca51ec1
Parents: f37ca20
Author: Paul King <paulk@asert.com.au>
Authored: Sat May 19 09:33:23 2018 +1000
Committer: Paul King <paulk@asert.com.au>
Committed: Sat May 19 09:33:23 2018 +1000

----------------------------------------------------------------------
 src/main/groovy/groovy/ui/GroovyMain.java | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/groovy/blob/7d4cd792/src/main/groovy/groovy/ui/GroovyMain.java
----------------------------------------------------------------------
diff --git a/src/main/groovy/groovy/ui/GroovyMain.java b/src/main/groovy/groovy/ui/GroovyMain.java
index eb2db46..58c6635 100644
--- a/src/main/groovy/groovy/ui/GroovyMain.java
+++ b/src/main/groovy/groovy/ui/GroovyMain.java
@@ -125,7 +125,6 @@ public class GroovyMain {
     static void processArgs(String[] args, final PrintStream out, final PrintStream err)
{
         GroovyCommand groovyCommand = new GroovyCommand();
         CommandLine parser = new CommandLine(groovyCommand).setUnmatchedArgumentsAllowed(true).setStopAtUnmatched(true);
-        parser.getCommandSpec().mixinStandardHelpOptions(true);
         try {
             List<CommandLine> result = parser.parse(args);
             if (CommandLine.printHelpIfRequested(result, out, err, Help.Ansi.AUTO)) {
@@ -215,6 +214,12 @@ public class GroovyMain {
         @Option(names = {"-b", "--basescript"}, paramLabel = "<class>", description
= "Base class name for scripts (must derive from Script)")
         private String scriptBaseClass;
 
+        @Option(names = {"-h", "--help"}, usageHelp = true, description = "Show this help
message and exit")
+        private boolean helpRequested;
+
+        @Option(names = {"-v", "--version"}, versionHelp = true, description = "Print version
information and exit")
+        private boolean versionRequested;
+
         @Unmatched
         List<String> arguments = new ArrayList<String>();
 


Mime
View raw message