Update bash script to support symlinks #1

Closed
cereda opened this Issue Apr 16, 2012 · 2 comments

2 participants

@cereda
Owner

Currently, the bash script arara only provides an access to the .jar file via the export method. Calling it from a symbolic link won't work.

@josephwright

Robust bash script which works with symlinks (even relative ones):

#!/bin/bash
SOURCE="${BASH_SOURCE[0]}"
while [ -h "$SOURCE" ] ; do SOURCE="$(readlink "$SOURCE")"; done
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && cd -P "$( dirname "$SOURCE" )" && pwd )"
java -jar "$DIR/arara.jar" $*
@cereda cereda was assigned Apr 24, 2012
@cereda
Owner

Thanks Joseph! Updated in version 2.0. Closed as solved.

@cereda cereda closed this Jul 20, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment