vim, gitconfig, update.sh
[dotfiles_afify.git] / .scripts / hostname.sh
blobb0e12bfc44c33761b6f584f75dc1a2d9ad364d97
1 #!/bin/sh
3 [ "$(uname)" = "OpenBSD" ] &&\
4 doas hostname openbsd && doas echo "openbsd" > /etc/myname &&\
5 doas printf "127.0.0.1\t openbsd\tlocalhost\n::1\topenbsd localhost\n" > /etc/hosts
7 [ "$(uname)" = "Linux" ] &&\
8 doas hostname alien && doas echo "alien" > /etc/hostname &&\
9 doas printf "127.0.0.1\t alien\tlocalhost\n::1\talien localhost\n" > /etc/hosts