fixed rofi scripts

This commit is contained in:
Clay Gomera 2023-06-24 13:01:17 -04:00
parent aac64b4fab
commit a9900e45b1
3 changed files with 13 additions and 31 deletions

View file

@ -8,9 +8,6 @@
## MENU PROMPT ## ## MENU PROMPT ##
menu="rofi -dmenu -i -p" menu="rofi -dmenu -i -p"
## CURRENT WALLPAPER FOR LOCKSCREEN ##
currwall=$(tail --l 1 "$HOME/.wbg" | awk '{print $3}')
## OPTIONS ## ## OPTIONS ##
option1=" Logout" option1=" Logout"
option2=" Reboot" option2=" Reboot"

View file

@ -2,11 +2,11 @@
# ***This script was made by Clay Gomera (Drake)*** # ***This script was made by Clay Gomera (Drake)***
# - Description: A simple screenshot dmenu script # - Description: A simple screenshot dmenu script
# - Dependencies: scrot, dmenu, notify-send # - Dependencies: escrotum, dmenu, notify-send
## CREATING SCREENSHOT FOLDER ## ## CREATING SCREENSHOT FOLDER ##
mkdir -p "$HOME/Pictures/Screenshots" mkdir -p "$HOME/Media/Pictures/Screenshots"
cd "$HOME/Pictures/Screenshots" || exit 0 cd "$HOME/Media/Pictures/Screenshots" || exit 0
## CHOICES ## ## CHOICES ##
cho1="󱣴 Entire screen" cho1="󱣴 Entire screen"
@ -21,9 +21,13 @@ del2="󱑂 5 sec delay"
del3="󱑇 10 sec delay" del3="󱑇 10 sec delay"
dels="$del1\n$del2\n$del3" dels="$del1\n$del2\n$del3"
## DELAY FUNCTION ## ## MAIN ACTION ##
delays() { choice=$(echo -e "$chos" | rofi -dmenu -i -p "  Sreenshot Menu ")
del=$(echo -e "$dels" | rofi -dmenu -i -p "  Select Delay "); case $choice in
"$cho1")
escrotum && notify-send "Screenshot saved";;
"$cho2")
del=$(echo -e "$dels" | rofi -dmenu -i -p "  Select Delay ");
case $del in case $del in
"$del1") "$del1")
escrotum -d 3 -C && notify-send "Screenshot saved";; escrotum -d 3 -C && notify-send "Screenshot saved";;
@ -31,28 +35,9 @@ delays() {
escrotum -d 5 -C && notify-send "Screenshot saved";; escrotum -d 5 -C && notify-send "Screenshot saved";;
"$del3") "$del3")
escrotum -d 10 -C && notify-send "Screenshot saved" escrotum -d 10 -C && notify-send "Screenshot saved"
esac esac ;;
}
## ENTIRE SCREEN FUNCTION ##
screen() {
escrotum && notify-send "Screenshot saved"
}
## SELECTED AREA FUNCTION ##
selectw() {
escrotum -s && notify-send "Screenshot saved."
}
## MAIN ACTION ##
choice=$(echo -e "$chos" | rofi -dmenu -i -p "  Sreenshot Menu ")
case $choice in
"$cho1")
screen;;
"$cho2")
delays;;
"$cho3") "$cho3")
selectw;; escrotum -s && notify-send "Screenshot saved.";;
"$cho4") "$cho4")
exit 0 exit 0
esac esac

View file

@ -5,7 +5,7 @@
# - Dependencies: rofi, fd, feh # - Dependencies: rofi, fd, feh
## MAIN VARIABLES AND COMMANDS ## ## MAIN VARIABLES AND COMMANDS ##
walldir="Pictures/Wallpapers" # wallpapers folder, change it to yours, make sure that it ends with a / walldir="$HOME/Media/Pictures/Wallpapers"
cd "$walldir" || exit cd "$walldir" || exit
## SELECT PICTURE FUNCTION ## ## SELECT PICTURE FUNCTION ##