Skip to content

Commit

Permalink
[HEADLESS] Fix command to work though symlink
Browse files Browse the repository at this point in the history
In preparation for issue #3474 - ensure that the command 'gama-headless' added in the system path with a symbolic link (symlink) grab properly files in installed directory
  • Loading branch information
RoiArthurB committed Oct 18, 2022
1 parent a0ca6ea commit 240559e
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion travis/jdk/linux/gama-headless.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ else
passWork=.workspace$(find ./ -maxdepth 1 -name ".workspace*" | wc -l)
fi

if ! "$( dirname "${BASH_SOURCE[0]}" )"/../jdk/bin/java -cp "$( dirname "${BASH_SOURCE[0]}" )"/../plugins/org.eclipse.equinox.launcher*.jar -Xms512m -Xmx$memory -Djava.awt.headless=true org.eclipse.core.launcher.Main -application msi.gama.headless.id4 -data $passWork "$@"; then
if ! "$( dirname $( realpath "${BASH_SOURCE[0]}" ) )"/../jdk/bin/java -cp "$( dirname $( realpath "${BASH_SOURCE[0]}" ) )"/../plugins/org.eclipse.equinox.launcher*.jar -Xms512m -Xmx$memory -Djava.awt.headless=true org.eclipse.core.launcher.Main -application msi.gama.headless.id4 -data $passWork "$@"; then
echo "Error in you command, here's the log :"
cat $passWork/.metadata/.log
exit 1
Expand Down
2 changes: 1 addition & 1 deletion travis/jdk/mac/gama-headless.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ else
passWork=.workspace$(find ./ -maxdepth 1 -name ".workspace*" | wc -l)
fi

if ! "$( dirname "${BASH_SOURCE[0]}" )"/../jdk/Contents/Home/bin/java -cp "$( dirname "${BASH_SOURCE[0]}" )"/../Eclipse/plugins/org.eclipse.equinox.launcher*.jar -Xms512m -Xmx$memory -Djava.awt.headless=true org.eclipse.core.launcher.Main -application msi.gama.headless.id4 -data $passWork "$@"; then
if ! "$( dirname $( realpath "${BASH_SOURCE[0]}" ) )"/../jdk/Contents/Home/bin/java -cp "$( dirname $( realpath "${BASH_SOURCE[0]}" ) )"/../Eclipse/plugins/org.eclipse.equinox.launcher*.jar -Xms512m -Xmx$memory -Djava.awt.headless=true org.eclipse.core.launcher.Main -application msi.gama.headless.id4 -data $passWork "$@"; then
echo "Error in you command, here's the log :"
cat $passWork/.metadata/.log
exit 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ else
passWork=${@: -1}/.workspace$(find ${@: -1} -name ".workspace*" | expr $(wc -l))
fi

if ! java -cp "$( dirname "${BASH_SOURCE[0]}" )"/../Eclipse/plugins/org.eclipse.equinox.launcher*.jar -Xms512m -Xmx$memory -Djava.awt.headless=true org.eclipse.core.launcher.Main -application msi.gama.headless.id4 -data $passWork "$@"; then
if ! java -cp "$( dirname $( realpath "${BASH_SOURCE[0]}" ) )"/../Eclipse/plugins/org.eclipse.equinox.launcher*.jar -Xms512m -Xmx$memory -Djava.awt.headless=true org.eclipse.core.launcher.Main -application msi.gama.headless.id4 -data $passWork "$@"; then
echo "Error in you command, here's the log :"
cat $passWork/.metadata/.log
exit 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ else
passWork=.workspace$(find ./ -maxdepth 1 -name ".workspace*" | wc -l)
fi

if ! java -cp "$( dirname "${BASH_SOURCE[0]}" )"/../plugins/org.eclipse.equinox.launcher*.jar -Xms512m -Xmx$memory -Djava.awt.headless=true org.eclipse.core.launcher.Main -application msi.gama.headless.id4 -data $passWork "$@"; then
if ! java -cp "$( dirname $( realpath "${BASH_SOURCE[0]}" ) )"/../plugins/org.eclipse.equinox.launcher*.jar -Xms512m -Xmx$memory -Djava.awt.headless=true org.eclipse.core.launcher.Main -application msi.gama.headless.id4 -data $passWork "$@"; then
echo "Error in you command, here's the log :"
cat $passWork/.metadata/.log
exit 1
Expand Down

0 comments on commit 240559e

Please sign in to comment.