Redone the vpntoggle script
This commit is contained in:
		@@ -111,7 +111,8 @@ Script taken from Luke Smith.
 | 
			
		||||
  if [[ $(nordvpn status) == *"Connected"* ]]; then
 | 
			
		||||
    nordvpn disconnect && dunstify --replace=23198 "VPN" "Disconnected";
 | 
			
		||||
  else
 | 
			
		||||
    country=`nordvpn countries | sed 's/\s*\t\s*/ /g ; s/\s/\n/g ; s/_/ /g ; /^[a-zA-Z]/!d ; s/\(.*\)/\L\1/' | rofi -i -dmenu | sed 's/\s/_/g'`
 | 
			
		||||
    country=`cat ~/bin/nordvpn_countries.txt | sed 's/\s*\t\s*/ /g ; s/\s/\n/g ; s/_/ /g ; /^[a-zA-Z]/!d ; s/\(.*\)/\L\1/' | rofi -i -dmenu | sed 's/\s/_/g'`;
 | 
			
		||||
    dunstify --replace=23198 "VPN" "Connecting to $country...";
 | 
			
		||||
    nordvpn connect $country && dunstify --replace=23198 "VPN" "Connected to $country";
 | 
			
		||||
  fi
 | 
			
		||||
#+end_src
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user