bournified and added write option/default just shows

This commit is contained in:
Andrew Holland 2017-09-16 01:43:31 +03:00
parent 1372e2d20a
commit 9ef1a8b186

View file

@ -1,5 +1,9 @@
#!/bin/zsh
cd /tmp/
#!/bin/sh
cd /tmp/ || exit 'cd did not work'
curl -o resolv.conf -L "https://api.opennicproject.org/geoip/?resolv&ipv=4"
sudo mv resolv.conf /etc/
if [ "$1" = 'write' ]; then
sudo mv resolv.conf /etc/
else
less resolv.conf
fi