Browse Source

Fix problems picked up by review

Signed-off-by: Gavin Halliday <gavin.halliday@lexisnexis.com>
Gavin Halliday 3 years ago
parent
commit
6628f33dc5
3 changed files with 6 additions and 4 deletions
  1. 1 1
      ecl/eclcc/eclcc.hpp
  2. 1 1
      ecl/eclcmd/eclcmd_common.cpp
  3. 4 2
      system/jlib/jargv.cpp

+ 1 - 1
ecl/eclcc/eclcc.hpp

@@ -85,7 +85,7 @@ const char * const helpText[] = {
     "!   -brk <n>      Trigger a break point in eclcc after nth allocation",
 #endif
     "!   -Dname=value  Override the definition of a global attribute 'name'",
-    "!?  --defaultgitprefix <prefix>  The default prefix used to access git repos when not specified in package.json",
+    "?!  --defaultgitprefix <prefix>  The default prefix used to access git repos when not specified in package.json",
     "!   --deny=all    Disallow use of all named features not specifically allowed using --allow",
     "!   --deny=str    Disallow use of named feature",
     "!   --expand <path> Expand the contents of an archive to a directory",

+ 1 - 1
ecl/eclcmd/eclcmd_common.cpp

@@ -690,7 +690,7 @@ eclCmdOptionMatchIndicator EclCmdWithEclTarget::matchCommandLineOption(ArgvItera
     //Process options which should be passed straight through to eclcc
     StringBuffer temp;
     if (iter.matchOptionText(temp, ECLOPT_FETCH_REPOS, true, false) || iter.matchOptionText(temp, ECLOPT_UPDATE_REPOS, true, false) ||
-        iter.matchOptionText(temp, ECLOPT_DEFAULT_GIT_PREFIX, true, false) || iter.matchOptionText(temp, ECLOPT_REPO_MAPPING, false, true))
+        iter.matchOptionText(temp, ECLOPT_DEFAULT_GIT_PREFIX, false, false) || iter.matchOptionText(temp, ECLOPT_REPO_MAPPING, false, true))
     {
         extraOptions.append(temp);
         return EclCmdOptionMatch;

+ 4 - 2
system/jlib/jargv.cpp

@@ -244,7 +244,6 @@ bool ArgvIterator::matchOptionText(StringBuffer & option, const char * name, boo
         return false;
     }
 
-    option.append(arg);
     //Boolean flags don't check the next argument, options do if there was no =...
     if (!isBoolFlag)
     {
@@ -252,7 +251,10 @@ bool ArgvIterator::matchOptionText(StringBuffer & option, const char * name, boo
             return false;
 
         next();
-        option.append("=").append(query());
+        option.append(arg).append(" ").append(query());
     }
+    else
+        option.append(arg);
+
     return true;
 }