Correction : tool=$(readlink "$tool") .
authorJulien Moutinho <julm+burette@autogeree.net>
Sun, 24 Feb 2013 15:46:01 +0000 (16:46 +0100)
committerJulien Moutinho <julm+burette@autogeree.net>
Mon, 25 Feb 2013 22:36:00 +0000 (23:36 +0100)
vm_hosted

index 87182dc..b3e38ba 100755 (executable)
--- 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 () {