bournified and added write option/default just shows
This commit is contained in:
parent
1372e2d20a
commit
9ef1a8b186
1 changed files with 7 additions and 3 deletions
10
fixdns.sh
10
fixdns.sh
|
|
@ -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
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue