Merge pull request #425 from TheSerapher/cronhome-fix-symlink
Fix CRONHOME detection if a symlink is used
This commit is contained in:
commit
b88cdc135c
@ -28,7 +28,11 @@ VERBOSE="0"
|
|||||||
################################################################
|
################################################################
|
||||||
|
|
||||||
# Find scripts path
|
# Find scripts path
|
||||||
CRONHOME=$( dirname $0 )
|
if [[ -L $0 ]]; then
|
||||||
|
CRONHOME=$( dirname $( readlink $0 ) )
|
||||||
|
else
|
||||||
|
CRONHOME=$( dirname $0 )
|
||||||
|
fi
|
||||||
|
|
||||||
# Change working director to CRONHOME
|
# Change working director to CRONHOME
|
||||||
if ! cd $CRONHOME 2>/dev/null; then
|
if ! cd $CRONHOME 2>/dev/null; then
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user