Changeset 15916 in josm
- Timestamp:
- 2020-02-23T22:05:36+01:00 (5 years ago)
- Location:
- trunk
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/linux/latest/DEBIAN/postinst
r7506 r15916 2 2 set -e 3 3 # Automatically added by dh_installmenu 4 if [ "$1" = "configure" ] && [ -x " `which update-menus 2>/dev/null`" ]; then4 if [ "$1" = "configure" ] && [ -x "$(which update-menus 2>/dev/null)" ]; then 5 5 update-menus 6 6 fi -
trunk/linux/latest/DEBIAN/postrm
r7506 r15916 2 2 set -e 3 3 # Automatically added by dh_installmenu 4 if [ -x " `which update-menus 2>/dev/null`" ]; then update-menus ; fi4 if [ -x "$(which update-menus 2>/dev/null)" ]; then update-menus ; fi 5 5 # End automatically added section -
trunk/linux/latest/usr/bin/josm-latest
r15914 r15916 1 #!/bin/ sh1 #!/bin/bash 2 2 # Simple wrapper script used to start JOSM in Debian 3 3 set -e … … 5 5 # First, the alternative (if known to work) or users preference as defined by $JAVA_HOME. Next, use OpenJDK. 6 6 # Override to a specific one using $JAVACMD 7 ALTERNATIVE_JDK= "`readlink -n -f /etc/alternatives/java`"7 ALTERNATIVE_JDK=$(readlink -n -f /etc/alternatives/java) 8 8 9 9 # Let's get the current architecture -- needed for multiarchified Java 10 ARCH= "`dpkg --print-architecture 2> /dev/null || true`"10 ARCH=$(dpkg --print-architecture 2> /dev/null || true) 11 11 12 12 JAVA_CMDS="$JAVA_HOME/bin/java" 13 13 14 14 # If OpenJDK is only available headless, do not try it 15 if dpkg --get-selections 'openjdk-*-jre'| grep install$ > /dev/null \16 || dpkg --get-selections 'openjdk-*-jre:$ARCH'| grep install$ > /dev/null ; then15 if dpkg --get-selections "openjdk-*-jre" | grep install$ > /dev/null \ 16 || dpkg --get-selections "openjdk-*-jre:$ARCH" | grep install$ > /dev/null ; then 17 17 # LTS versions in decreased order 18 18 JAVA_CMDS="${JAVA_CMDS} /usr/lib/jvm/java-11-openjdk/bin/java /usr/lib/jvm/java-11-openjdk-$ARCH/bin/java" … … 38 38 if [ -z "${JAVACMD}" ]; then 39 39 for jcmd in $JAVA_CMDS; do 40 if [ "z$ALTERNATIVE_JDK" = "z `readlink -n -f $jcmd`" ] && [ -z "${JAVACMD}" ]; then40 if [ "z$ALTERNATIVE_JDK" = "z$(readlink -n -f "$jcmd")" ] && [ -z "${JAVACMD}" ]; then 41 41 JAVACMD="$jcmd" 42 42 break … … 47 47 if [ -z "${JAVACMD}" ]; then 48 48 for jcmd in $JAVA_CMDS; do 49 if [ -x "$jcmd" -a-z "${JAVACMD}" ]; then49 if [ -x "$jcmd" ] && [ -z "${JAVACMD}" ]; then 50 50 JAVACMD="$jcmd" 51 51 break … … 56 56 if [ "$JAVACMD" ]; then 57 57 echo "Using $JAVACMD to execute josm-latest." || true 58 if [ "`expr match \"${JAVACMD}\" 'java-9'`" != "0" ] || [ "`expr match \"${JAVACMD}\" 'java-10'`" != "0"]; then58 if [[ "${JAVACMD}" =~ 'java-9' ]] || [[ "${JAVACMD}" =~ 'java-10' ]]; then 59 59 JAVA_OPTS="--add-modules java.activation,java.se.ee $JAVA_OPTS" 60 elif [ "`expr match \"${JAVACMD}\" 'java-1'`" != "0"]; then60 elif [[ "${JAVACMD}" =~ 'java-1' ]]; then 61 61 JAVA_OPTS="--add-modules java.scripting,java.sql $JAVA_OPTS" 62 62 fi 63 63 set +e 64 64 while true; do 65 $JAVACMD $JAVA_OPTS-jar /usr/share/josm-latest/josm-latest.jar "$@"65 $JAVACMD "$JAVA_OPTS" -jar /usr/share/josm-latest/josm-latest.jar "$@" 66 66 if [ "z$?" != "z9" ]; then 67 67 break -
trunk/linux/tested/DEBIAN/postinst
r7506 r15916 2 2 set -e 3 3 # Automatically added by dh_installmenu 4 if [ "$1" = "configure" ] && [ -x " `which update-menus 2>/dev/null`" ]; then4 if [ "$1" = "configure" ] && [ -x "$(which update-menus 2>/dev/null)" ]; then 5 5 update-menus 6 6 fi -
trunk/linux/tested/DEBIAN/postrm
r7506 r15916 2 2 set -e 3 3 # Automatically added by dh_installmenu 4 if [ -x " `which update-menus 2>/dev/null`" ]; then update-menus ; fi4 if [ -x "$(which update-menus 2>/dev/null)" ]; then update-menus ; fi 5 5 # End automatically added section -
trunk/linux/tested/usr/bin/josm
r15914 r15916 1 #!/bin/ sh1 #!/bin/bash 2 2 # Simple wrapper script used to start JOSM in Debian 3 3 set -e … … 5 5 # First, the alternative (if known to work) or users preference as defined by $JAVA_HOME. Next, use OpenJDK. 6 6 # Override to a specific one using $JAVACMD 7 ALTERNATIVE_JDK= "`readlink -n -f /etc/alternatives/java`"7 ALTERNATIVE_JDK=$(readlink -n -f /etc/alternatives/java) 8 8 9 9 # Let's get the current architecture -- needed for multiarchified Java 10 ARCH= "`dpkg --print-architecture 2> /dev/null || true`"10 ARCH=$(dpkg --print-architecture 2> /dev/null || true) 11 11 12 12 JAVA_CMDS="$JAVA_HOME/bin/java" 13 13 14 14 # If OpenJDK is only available headless, do not try it 15 if dpkg --get-selections 'openjdk-*-jre'| grep install$ > /dev/null \16 || dpkg --get-selections 'openjdk-*-jre:$ARCH'| grep install$ > /dev/null ; then15 if dpkg --get-selections "openjdk-*-jre" | grep install$ > /dev/null \ 16 || dpkg --get-selections "openjdk-*-jre:$ARCH" | grep install$ > /dev/null ; then 17 17 # LTS versions in decreased order 18 18 JAVA_CMDS="${JAVA_CMDS} /usr/lib/jvm/java-11-openjdk/bin/java /usr/lib/jvm/java-11-openjdk-$ARCH/bin/java" … … 38 38 if [ -z "${JAVACMD}" ]; then 39 39 for jcmd in $JAVA_CMDS; do 40 if [ "z$ALTERNATIVE_JDK" = "z `readlink -n -f $jcmd`" ] && [ -z "${JAVACMD}" ]; then40 if [ "z$ALTERNATIVE_JDK" = "z$(readlink -n -f "$jcmd")" ] && [ -z "${JAVACMD}" ]; then 41 41 JAVACMD="$jcmd" 42 42 break … … 47 47 if [ -z "${JAVACMD}" ]; then 48 48 for jcmd in $JAVA_CMDS; do 49 if [ -x "$jcmd" -a-z "${JAVACMD}" ]; then49 if [ -x "$jcmd" ] && [ -z "${JAVACMD}" ]; then 50 50 JAVACMD="$jcmd" 51 51 break … … 56 56 if [ "$JAVACMD" ]; then 57 57 echo "Using $JAVACMD to execute josm." || true 58 if [ "`expr match \"${JAVACMD}\" 'java-9'`" != "0" ] || [ "`expr match \"${JAVACMD}\" 'java-10'`" != "0"]; then58 if [[ "${JAVACMD}" =~ 'java-9' ]] || [[ "${JAVACMD}" =~ 'java-10' ]]; then 59 59 JAVA_OPTS="--add-modules java.activation,java.se.ee $JAVA_OPTS" 60 elif [ "`expr match \"${JAVACMD}\" 'java-1'`" != "0"]; then60 elif [[ "${JAVACMD}" =~ 'java-1' ]]; then 61 61 JAVA_OPTS="--add-modules java.scripting,java.sql $JAVA_OPTS" 62 62 fi 63 63 set +e 64 64 while true; do 65 $JAVACMD $JAVA_OPTS-jar /usr/share/josm/josm.jar "$@"65 $JAVACMD "$JAVA_OPTS" -jar /usr/share/josm/josm.jar "$@" 66 66 if [ "z$?" != "z9" ]; then 67 67 break -
trunk/scripts/optimize-images
r13283 r15916 1 1 #!/bin/sh 2 2 3 for x in $(find images/ -name "*.png"); do 4 echo "Processing ${x}" 5 optipng -o7 -quiet "${x}" 6 done 3 find images/ -name "*.png" \ 4 -exec echo "Processing {}" \; \ 5 -exec optipng -o7 -quiet "{}" \;
Note:
See TracChangeset
for help on using the changeset viewer.