Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 24979aa1e -> d1110364c


PHOENIX-1903 bin scripts locate wrong client jar


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

Branch: refs/heads/4.x-HBase-0.98
Commit: d1110364c52f18462cb1bd0cac2bba92eb92e926
Parents: 24979aa
Author: Nick Dimiduk <[email protected]>
Authored: Tue Apr 21 16:17:42 2015 -0700
Committer: Nick Dimiduk <[email protected]>
Committed: Tue Apr 21 16:17:56 2015 -0700

----------------------------------------------------------------------
 bin/phoenix_utils.py | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/phoenix/blob/d1110364/bin/phoenix_utils.py
----------------------------------------------------------------------
diff --git a/bin/phoenix_utils.py b/bin/phoenix_utils.py
index 7ef8d96..554b21b 100755
--- a/bin/phoenix_utils.py
+++ b/bin/phoenix_utils.py
@@ -32,6 +32,8 @@ def find(pattern, classPaths):
             path = path[:-1]
     
         for root, dirs, files in os.walk(path):
+            # sort the file names so *-client always precedes *-thin-client
+            files.sort()
             for name in files:
                 if fnmatch.fnmatch(name, pattern):
                     return os.path.join(root, name)
@@ -41,6 +43,8 @@ def find(pattern, classPaths):
 def findFileInPathWithoutRecursion(pattern, path):
 
     files = [f for f in os.listdir(path) if 
os.path.isfile(os.path.join(path,f))]
+    # sort the file names so *-client always precedes *-thin-client
+    files.sort()
     for name in files:
         if fnmatch.fnmatch(name, pattern):
             return os.path.join(path, name)
@@ -108,4 +112,4 @@ def shell_quote(args):
     else:
         # pipes module isn't available on Windows
         import pipes
-        return " ".join([pipes.quote(v) for v in args])
\ No newline at end of file
+        return " ".join([pipes.quote(v) for v in args])

Reply via email to