Remove videocall script

This commit is contained in:
coolneng 2022-05-11 11:22:05 +02:00
parent 867b817501
commit f51da4431d
Signed by: coolneng
GPG Key ID: 9893DA236405AF57
2 changed files with 1 additions and 37 deletions

View File

@ -5,8 +5,6 @@ select_action() {
"System resources usage" "System resources usage"
"Connectivity test" "Connectivity test"
"Sync Doom emacs" "Sync Doom emacs"
"Start videocall"
"Stop videocall"
"Sync mail" "Sync mail"
) )
action=$(printf '%s\n' "${action_content[@]}" | rofi -no-auto-select -i "$@" -dmenu -p "Choose an action") action=$(printf '%s\n' "${action_content[@]}" | rofi -no-auto-select -i "$@" -dmenu -p "Choose an action")
@ -26,12 +24,8 @@ execute_action() {
"System resources usage") launch_kitty "htop" ;; "System resources usage") launch_kitty "htop" ;;
"Connectivity test") launch_kitty "ping -c 2 freebsd.org" ;; "Connectivity test") launch_kitty "ping -c 2 freebsd.org" ;;
"Sync doom emacs") execute_command "$HOME/.emacs.d/bin/doom sync" ;; "Sync doom emacs") execute_command "$HOME/.emacs.d/bin/doom sync" ;;
"Start videocall") execute_command "$script_folder/pulseaudio-mic-mute" && execute_command "$script_folder/videocall start" ;; "Sync mail") execute_command "/home/coolnengs/.local/share/scripts/mail-sync -a" ;;
"Stop videocall") execute_command "$script_folder/pulseaudio-mic-mute" && execute_command "$script_folder/videocall stop" ;;
"Sync mail") execute_command "/home/coolnengs/.local/share/scripts/mail-sync" ;;
esac esac
} }
script_folder="$HOME/.local/share/scripts"
select_action "$@" select_action "$@"

View File

@ -1,30 +0,0 @@
#!/bin/sh
usage() {
echo "Usage: videocall <start|stop>"
exit 1
}
move_workspace() {
swaymsg workspace "$1", move workspace to "$2"
}
main() {
if [ "$1" = "start" ]; then
move_workspace "3: " "HDMI-A-2"
move_workspace "2: " "eDP-1"
elif [ "$1" = "stop" ]; then
move_workspace "3: " "eDP-1"
move_workspace "2: " "HDMI-A-2"
else
usage
fi
}
if [ $# -lt 1 ]; then
usage
fi
action=$1
main "$action"