torrent wrap and other changes
This commit is contained in:
parent
151e47c629
commit
9ddf765a03
3 changed files with 11 additions and 10 deletions
|
@ -286,7 +286,7 @@ bindsym $mod+F2 restart
|
|||
bindsym $mod+F3 exec --no-startup-id displayselect
|
||||
bindsym $mod+F4 exec --no-startup-id prompt "Hibernate computer?" "$hibernate"
|
||||
bindsym $mod+F5 exec --no-startup-id $netrefresh
|
||||
bindsym $mod+F6 exec --no-startup-id $term -e transmission-remote-cli
|
||||
bindsym $mod+F6 exec --no-startup-id torwrap
|
||||
bindsym $mod+F7 exec --no-startup-id td-toggle
|
||||
bindsym $mod+F8 exec --no-startup-id ~/.config/mutt/etc/mailsync.sh
|
||||
bindsym $mod+F9 exec --no-startup-id dmenumount
|
||||
|
|
|
@ -1,15 +1,10 @@
|
|||
#!/bin/sh
|
||||
|
||||
# If transmission-daemon is running, will ask to kill, else will ask to start.
|
||||
|
||||
[ ! -f /usr/bin/transmission-daemon ] && notify-send "Transmission daemon not installed." && exit
|
||||
|
||||
if pgrep -x transmission-da >/dev/null ;
|
||||
if pgrep -x transmission-da >/dev/null ;
|
||||
then
|
||||
yn=$(printf "No\\nYes" | dmenu -i -p "Kill transmission-daemon?")
|
||||
[ "$yn" = "Yes" ] && killall transmission-da
|
||||
[ "$(printf "No\\nYes" | dmenu -i -p "Kill transmission-daemon?")" = "Yes" ] && killall transmission-da && notify-send -i "$PIX/torrent.svg" "transmission-daemon killed."
|
||||
else
|
||||
yn=$(printf "No\\nYes" | dmenu -i -p "Start transmission daemon?")
|
||||
[ "$yn" = "Yes" ] && transmission-daemon
|
||||
ifinstalled transmission-cli || exit
|
||||
[ "$(printf "No\\nYes" | dmenu -i -p "Start transmission daemon?")" = "Yes" ] && transmission-daemon && notify-send -i "$PIX/torrent.svg" "tranmission-daemon started."
|
||||
fi
|
||||
sleep 3 && pkill -RTMIN+7 i3blocks
|
||||
|
|
6
.scripts/i3cmds/torwrap
Executable file
6
.scripts/i3cmds/torwrap
Executable file
|
@ -0,0 +1,6 @@
|
|||
#!/bin/sh
|
||||
ifinstalled transmission-remote-cli transmission-cli || exit
|
||||
|
||||
! pgrep -x transmission-da >/dev/null && transmission-daemon && notify-send -i "$PIX/torrent.svg" "Starting torrent daemon..." && sleep 3 && pkill -RTMIN+7 i3blocks
|
||||
|
||||
$TERMINAL -e transmission-remote-cli
|
Loading…
Reference in a new issue