Handle tabs in /etc/hosts
This commit is contained in:
parent
e0d2424d5e
commit
5d68e2cc70
@ -28,7 +28,7 @@ start()
|
|||||||
# because it makes some of the pre-created dotfiles invalid (e.g. .kde/cache-<hostname>)
|
# because it makes some of the pre-created dotfiles invalid (e.g. .kde/cache-<hostname>)
|
||||||
# (let's be frank: nobody's gonna use xterm on DispVM)
|
# (let's be frank: nobody's gonna use xterm on DispVM)
|
||||||
hostname $name
|
hostname $name
|
||||||
sed -i "s/^\(127\.0\.0\.1 .*\) \($name \)\?\(.*\)/\1\2 $name/" /etc/hosts
|
sed -i "s/^\(127\.0\.0\.1[\t ].*\) \($name \)\?\(.*\)/\1\2 $name/" /etc/hosts
|
||||||
fi
|
fi
|
||||||
|
|
||||||
timezone=`/usr/bin/xenstore-read qubes-timezone 2> /dev/null`
|
timezone=`/usr/bin/xenstore-read qubes-timezone 2> /dev/null`
|
||||||
|
@ -62,7 +62,7 @@ done
|
|||||||
name=`$XS_READ name`
|
name=`$XS_READ name`
|
||||||
if [ -n "$name" ]; then
|
if [ -n "$name" ]; then
|
||||||
hostname $name
|
hostname $name
|
||||||
sed -i "s/^\(127\.0\.0\.1 .*\) \($name \)\?\(.*\)/\1\2 $name/" /etc/hosts
|
sed -i "s/^\(127\.0\.0\.1[\t ].*\) \($name \)\?\(.*\)/\1\2 $name/" /etc/hosts
|
||||||
fi
|
fi
|
||||||
|
|
||||||
timezone=`$XS_READ qubes-timezone 2> /dev/null`
|
timezone=`$XS_READ qubes-timezone 2> /dev/null`
|
||||||
|
Loading…
Reference in New Issue
Block a user