mirror of
https://github.com/byReqz/netset.git
synced 2024-11-22 12:51:15 +00:00
add selector
This commit is contained in:
parent
3554d2b93d
commit
be403af671
10
netset.sh
Normal file → Executable file
10
netset.sh
Normal file → Executable file
@ -1,6 +1,10 @@
|
||||
#!/bin/bash
|
||||
# license: gpl-3
|
||||
|
||||
echo "which networkmanager do you want to use?"
|
||||
echo "please enter the name or number of your choice"
|
||||
echo "1. systemd-resolved"
|
||||
read $c1
|
||||
if [[ "$c1" == "1" ]] || [[ "$c1" == "1." ]] || [[ "$c1" == "systemd-resolved" ]];then
|
||||
if [[ -z $(sudo systemctl status systemd-networkd | grep -e "dead") ]];then
|
||||
if [[ $(ls -l /etc/systemd/network | wc -l) != 0 ]];then
|
||||
echo "warning, there already are configs present"
|
||||
@ -118,3 +122,7 @@ else
|
||||
echo "systemd-networkd is not running"
|
||||
exit
|
||||
fi
|
||||
else
|
||||
echo "selected manager not supported"
|
||||
exit
|
||||
fi
|
Loading…
Reference in New Issue
Block a user