mirror of
https://github.com/Keyitdev/dotfiles.git
synced 2026-09-24 01:52:09 +00:00
60 lines
1.2 KiB
Bash
Executable File
60 lines
1.2 KiB
Bash
Executable File
#!/bin/sh
|
|
|
|
# rofi theme
|
|
theme="$HOME/.config/rofi/main_without_icons.rasi"
|
|
|
|
get_options() {
|
|
echo " Selected area screenshot"
|
|
echo " Full screen screenshot"
|
|
echo " Selected area video"
|
|
echo " Full screen video"
|
|
echo " Record audio (microphone)"
|
|
echo " Record audio (desktop)"
|
|
echo " Selected area video with audio (microphone)"
|
|
echo " Full screen video with audio (microphone)"
|
|
echo " Stop Recording"
|
|
}
|
|
|
|
main() {
|
|
|
|
# get choice from rofi
|
|
choice=$( (get_options) | rofi -dmenu -i -fuzzy -p "" -theme "$theme")
|
|
|
|
# run the selected command
|
|
case $choice in
|
|
' Selected area screenshot')
|
|
screenshot -sa
|
|
;;
|
|
' Full screen screenshot')
|
|
screenshot -sf
|
|
;;
|
|
' Selected area video')
|
|
screenshot -va
|
|
;;
|
|
' Full screen video')
|
|
screenshot -vf
|
|
;;
|
|
' Record audio (microphone)')
|
|
screenshot -am
|
|
;;
|
|
' Record audio (desktop)')
|
|
screenshot -ad
|
|
;;
|
|
' Selected area video with audio (microphone)')
|
|
screenshot -vaam
|
|
;;
|
|
' Full screen video with audio (microphone)')
|
|
screenshot -vfam
|
|
;;
|
|
' Stop Recording')
|
|
screenshot -s
|
|
;;
|
|
esac
|
|
|
|
# done
|
|
set -e
|
|
}
|
|
|
|
main &
|
|
|
|
exit 0 |