mirror of
https://github.com/mitchell/dotfiles.git
synced 2025-12-17 12:27:22 +00:00
Improve ytmpv and redisco
This commit is contained in:
parent
0978eb701f
commit
e8e8b4ba3d
3 changed files with 54 additions and 37 deletions
|
|
@ -1,8 +1,20 @@
|
|||
function redisco
|
||||
while pgrep Discord >/dev/null 2>&1
|
||||
pkill Discord
|
||||
sleep 1
|
||||
set -l to_kill discord
|
||||
|
||||
if test -n "$argv"
|
||||
set to_kill $argv
|
||||
end
|
||||
|
||||
discord >/dev/null 2>&1 & disown
|
||||
pgrep -fia $to_kill
|
||||
or return
|
||||
|
||||
read -P 'continue? [Y/n]> ' -l confirm
|
||||
|
||||
if test "$confirm" = 'n'
|
||||
return
|
||||
end
|
||||
|
||||
pkill -fi $to_kill
|
||||
|
||||
nohup $to_kill &> /dev/null & disown
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue