Clone
Chris Sheedy <chris.sheedy@hp.com>
committed
on 11 Dec 14
Remove duplicates in PATH and CLASSPATH to fix bug 1401216
In sqf/sqenvcom.sh :
1. Removed duplicates from environment variables $CLASSPATH … Show more
Remove duplicates in PATH and CLASSPATH to fix bug 1401216

In sqf/sqenvcom.sh :

1. Removed duplicates from environment variables $CLASSPATH and $PATH,

  so sqenv.sh can be invoked repeatedly without them growing.

2. Removed test for JAVA_HOME containing exactly "1.7.0_67", which should

  help fix bug 1387238.

3. To reduce the places the recommended jdk version "1.7.0_67" appears,

  set this variable earlier:

    REQ_JDK_VER="1.7.0_67"

  This is used only in setting JAVA_HOME if it does not exist.

4. Removed jdk 1.6 lines since we stopped using that when directory

  sql/hbaseExtensions was removed about the end of September.

5. Made indentation more consistent.

6. Made formatting of "if" and "do" more consistent.

7. Used double-brackets in conditionals, which is safer as

  documented in http://mywiki.wooledge.org/BashFAQ/031

8. Use $(..) for subshells instead of less readable backticks.

In sqf/tools/sqtools.sh, added function remove_duplicates_in_path which

removes second and later appearances of the same value.

Change-Id: Iec48874b14d08ca8155006ab6a6a3f41c1714ca8

Show less

default + 10 more