X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=utils%2Finstall4j%2Finstall4j8_template.install4j;h=53f7853bb7df43968b6d1c1028450fe47aff646a;hb=2319ef1a410ce35bf2ef1800fd0be4e779ee44eb;hp=f4c560bf2d27b2282dff47cce18d2b6131bacdc6;hpb=256755ff43badc9ce0b5eb0de0bf8293585b9a4d;p=jalview.git diff --git a/utils/install4j/install4j8_template.install4j b/utils/install4j/install4j8_template.install4j index f4c560b..53f7853 100644 --- a/utils/install4j/install4j8_template.install4j +++ b/utils/install4j/install4j8_template.install4j @@ -1,6 +1,6 @@ - - + + @@ -34,9 +34,10 @@ - - - + + + + @@ -106,15 +107,11 @@ - - - + - - - + @@ -148,7 +145,7 @@ - + @@ -247,6 +244,35 @@ + + + + + String userHome = (String)context.getVariable("sys.userHome"); + +String[] tryPaths = new String[] { + "bin", + ".local" + File.separator + "bin", + "local" + File.separator + "bin", + "opt" + File.separator + "bin" +}; + +for (int i = 0; i < tryPaths.length; i++) { + String tryPath = tryPaths[i]; + File unixUserBinDir = new File(userHome + File.separator + tryPath); + if (unixUserBinDir.exists()) { + return tryPath; + } +} + +return null; + + + + unixUserBinDir + + Util.isLinux() || Util.isUnixInstaller() + @@ -493,7 +519,7 @@ return console.askOkCancel(message, true); - Creating file associations + Finished creating file associations @@ -507,19 +533,19 @@ return console.askOkCancel(message, true); - 737 + JALVIEW jalview - 737 + JALVIEW jalviews - 737 + JALVIEW ${compiler:EXTRA_SCHEME} @@ -591,6 +617,44 @@ return console.askOkCancel(message, true); context.getBooleanVariable("addToDockAction") + + + + + ${compiler:WRAPPER_SCRIPT_BIN_DIR}/${compiler:BASH_WRAPPER_SCRIPT} + + + + + ${compiler:WRAPPER_SCRIPT_BIN_DIR}/${compiler:WRAPPER_LINK} + + + + !Util.isWindows() + + + + + ${installer:sys.contentDir}\${compiler:WRAPPER_SCRIPT_BIN_DIR} + Path + + context.getBooleanVariable("appendToPathAction") + + + + + + ${installer:sys.contentDir}/${compiler:WRAPPER_SCRIPT_BIN_DIR}/${compiler:BASH_WRAPPER_SCRIPT} + + + + + ${installer:sys.userHome}/${installer:unixUserBinDir}/${compiler:WRAPPER_LINK} + + + + context.getBooleanVariable("makeSymbolicLink") && ( Util.isLinux() || Util.isUnixInstaller() ) && ( context.getVariable("unixUserBinDir") != null ) + @@ -613,6 +677,22 @@ return console.askOkCancel(message, true); Util.isMacOS() + + + Add ${compiler:JALVIEW_APPLICATION_NAME}'s bin folder to the Path environment variable + + appendToPathAction + + Util.isWindows() + + + + Make a ${compiler:WRAPPER_LINK} symbolic link in ~/${installer:unixUserBinDir} + + makeSymbolicLink + + ( Util.isLinux() || Util.isUnixInstaller() ) && ( context.getVariable("unixUserBinDir") != null ) + @@ -715,7 +795,7 @@ return console.askYesNo(message, true); - + jre @@ -898,32 +978,22 @@ return console.askYesNo(message, true); - jalviewc + ${compiler:WRAPPER_SCRIPT_BIN_DIR} - jalviewc-macos + bin - jalviewc.ps1 + channel.props - jalviewcv - - - - - jalviewc-macosv - - - - - jalview.ps1v + channel.propsv @@ -1185,7 +1255,7 @@ return console.askYesNo(message, true); - + @@ -1201,7 +1271,7 @@ return console.askYesNo(message, true); - + @@ -1217,11 +1287,11 @@ return console.askYesNo(message, true); - - + + - + @@ -1237,7 +1307,7 @@ return console.askYesNo(message, true); - + @@ -1253,7 +1323,7 @@ return console.askYesNo(message, true); - +