From 37112c72924262d89eb93d643b3c7d3c09a2834a Mon Sep 17 00:00:00 2001 From: kohsuke Date: Wed, 29 Apr 2009 00:33:29 +0000 Subject: [PATCH] handles Turkish correctly git-svn-id: https://hudson.dev.java.net/svn/hudson/trunk/hudson/main@17598 71c3de6d-444a-0410-be80-ed276b4c234a --- core/src/main/java/hudson/cli/CLICommand.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/core/src/main/java/hudson/cli/CLICommand.java b/core/src/main/java/hudson/cli/CLICommand.java index dca2df8121..2055267b54 100644 --- a/core/src/main/java/hudson/cli/CLICommand.java +++ b/core/src/main/java/hudson/cli/CLICommand.java @@ -36,6 +36,7 @@ import java.io.PrintStream; import java.io.InputStream; import java.io.BufferedInputStream; import java.util.List; +import java.util.Locale; /** * Base class for Hudson CLI. @@ -118,7 +119,8 @@ public abstract class CLICommand implements ExtensionPoint, Cloneable { name = name.substring(0,name.length()-7); // trim off the command // convert "FooBarZot" into "foo-bar-zot" - return name.replaceAll("([a-z0-9])([A-Z])","$1-$2").toLowerCase(); + // Locale is fixed so that "CreateInstance" always become "create-instance" no matter where this is run. + return name.replaceAll("([a-z0-9])([A-Z])","$1-$2").toLowerCase(Locale.ENGLISH); } public int main(List args, InputStream stdin, PrintStream stdout, PrintStream stderr) {