fix nerdfonts
This commit is contained in:
parent
91c28d507f
commit
79d0fcfdd1
4 changed files with 9 additions and 7 deletions
|
@ -10,5 +10,6 @@ password=$(find ~/.password-store/ -type f -name '*.gpg' | sed 's/.*\/\(.*\)\.gp
|
||||||
# Otherwise, copy to clipboard and notify OTP
|
# Otherwise, copy to clipboard and notify OTP
|
||||||
pass otp "$password" | while read -r OUTPUT; do
|
pass otp "$password" | while read -r OUTPUT; do
|
||||||
echo $OUTPUT | xsel -ib
|
echo $OUTPUT | xsel -ib
|
||||||
|
xdotool type "$OUTPUT"
|
||||||
notify-send " $password" "$OUTPUT"
|
notify-send " $password" "$OUTPUT"
|
||||||
done
|
done
|
||||||
|
|
|
@ -8,5 +8,6 @@ password=$(find ~/.password-store/ -type f -name '*.gpg' |
|
||||||
# Exit if none chosen
|
# Exit if none chosen
|
||||||
[ -z "$password" ] && exit
|
[ -z "$password" ] && exit
|
||||||
|
|
||||||
# If chosen, copy to clipboard, and notify
|
# If chosen, use xdotool to type it
|
||||||
pass show "$password" | head -1 | xsel -ib && notify-send " $password" "Copied to clipboard"
|
pass=$(pass show "$password" | head -1)
|
||||||
|
xdotool type "$pass" && notify-send " $password" "Successfully decrypted"
|
||||||
|
|
|
@ -9,17 +9,17 @@ network=$(iwctl station wlan0 get-networks | cut -d " " -f 7-21 | tail +5 | awk
|
||||||
iwctl station wlan0 connect --dont-ask "$network"
|
iwctl station wlan0 connect --dont-ask "$network"
|
||||||
sleep 2 # Bit of grace time
|
sleep 2 # Bit of grace time
|
||||||
# Exit with notification if $network is shown on status
|
# Exit with notification if $network is shown on status
|
||||||
iwctl station wlan0 show | grep "network" | awk '{print $3}' | grep -q "$network" && notify-send "直 Wireless Network" "Connected to $network" && exit
|
iwctl station wlan0 show | grep "network" | awk '{print $3}' | grep -q "$network" && notify-send " Wireless Network" "Connected to $network" && exit
|
||||||
|
|
||||||
# Try connecting with passphrase
|
# Try connecting with passphrase
|
||||||
pass=$(dmenu -p "Passphrase:" -P < /dev/null)
|
pass=$(dmenu -p "Passphrase:" -P < /dev/null)
|
||||||
# Test for empty password, exit if true
|
# Test for empty password, exit if true
|
||||||
[ -z "$pass" ] && notify-send "直 Wireless Network" "Invalid password: Empty" && exit
|
[ -z "$pass" ] && notify-send " Wireless Network" "Invalid password: Empty" && exit
|
||||||
# Attempt conection with provided pass, notify and exit on success
|
# Attempt conection with provided pass, notify and exit on success
|
||||||
iwctl --passphrase="$pass" station wlan0 connect --dont-ask "$network"
|
iwctl --passphrase="$pass" station wlan0 connect --dont-ask "$network"
|
||||||
sleep 2 # Bit of grace time
|
sleep 2 # Bit of grace time
|
||||||
# Exit with notification if $network is shown on status
|
# Exit with notification if $network is shown on status
|
||||||
iwctl station wlan0 show | grep "network" | awk '{print $3}' | grep -q "$network" && notify-send "直 Wireless Network" "Connected to $network" && exit
|
iwctl station wlan0 show | grep "network" | awk '{print $3}' | grep -q "$network" && notify-send " Wireless Network" "Connected to $network" && exit
|
||||||
|
|
||||||
# Notify unsuccessful operation
|
# Notify unsuccessful operation
|
||||||
notify-send "直 Wireless Network" "Operation unsuccessful"
|
notify-send " Wireless Network" "Operation unsuccessful"
|
||||||
|
|
|
@ -2,4 +2,4 @@
|
||||||
# Shortcut for scanning networks
|
# Shortcut for scanning networks
|
||||||
|
|
||||||
# Attempt to scan networks, notify operation success
|
# Attempt to scan networks, notify operation success
|
||||||
iwctl station wlan0 scan && notify-send "直 Wireless Network" "Scanning..." || notify-send " Wireless Network" "Operation unsuccessful"
|
iwctl station wlan0 scan && notify-send " Wireless Network" "Scanning..." || notify-send " Wireless Network" "Operation unsuccessful"
|
||||||
|
|
Loading…
Reference in a new issue