From: Julien Moutinho Date: Sun, 24 Feb 2013 15:46:01 +0000 (+0100) Subject: Correction : tool=$(readlink "$tool") . X-Git-Url: https://git.cyclocoop.org/?p=lhc%2Fateliers.git;a=commitdiff_plain;h=fcd70fe078a04a9bfe068a8c68d3e52c0ee6c8b2 Correction : tool=$(readlink "$tool") . --- diff --git a/vm_hosted b/vm_hosted index 87182dc..b3e38ba 100755 --- a/vm_hosted +++ b/vm_hosted @@ -1,6 +1,10 @@ #!/bin/sh set -e -f ${DRY_RUN:+-n} -u -tool=${0%/*} +tool=$0 +while test -L "$tool" + do tool=$(readlink "$tool") + done +tool=${tool%/*} . "$tool"/lib/rule.sh . "$tool"/etc/vm.sh @@ -30,6 +34,7 @@ rule_git_configure () { local tool tool=$(cd "$tool"; cd -) sudo ln -fns "$tool"/vm_hosted /usr/local/sbin/ + sudo ln -fns "$tool"/vm_hosted /usr/local/sbin/vm ) } rule_git_reset () {