diff options
author | makefu <github@syntax-fehler.de> | 2014-04-25 12:02:12 +0200 |
---|---|---|
committer | makefu <github@syntax-fehler.de> | 2014-04-25 12:02:12 +0200 |
commit | 9afc6e2d0237ae84c084cc05492bf0f285f98851 (patch) | |
tree | fcf6627e59387cbb5c3a19f10caa366dec39842a /retiolum/bin/update_tinc_hosts | |
parent | 9bdee602a30f715c9ba2583d3948c360448c670b (diff) | |
parent | 771b8cb9526255d54c8069b49503b427058a84b0 (diff) |
Merge branch 'master' of ssh://github.com/krebscode/painload
Diffstat (limited to 'retiolum/bin/update_tinc_hosts')
-rwxr-xr-x | retiolum/bin/update_tinc_hosts | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/retiolum/bin/update_tinc_hosts b/retiolum/bin/update_tinc_hosts index ce1be497..46076cf2 100755 --- a/retiolum/bin/update_tinc_hosts +++ b/retiolum/bin/update_tinc_hosts @@ -7,11 +7,8 @@ if test "${nosudo-false}" != true -a `id -u` != 0; then exit 23 # go to hell fi -list_hosts="$( - basename="`readlink -f "$0"`" - bindir="`dirname "$basename"`" - echo "$bindir/hosts" -)" +list_hosts=$(cd -P "$(dirname "$0")" && pwd -P)/hosts + hosts() { "$list_hosts"; } hosts="${hosts-/etc/hosts}" |