summaryrefslogtreecommitdiffstats
path: root/.scripts/killrecording
blob: b7c98270ce56685a922043f684f030d8d24c2f00 (plain) (blame)
1
2
3
4
5
6
7
8
9
#!/bin/bash
# I'm not quite sure why, but a new non-recording instance of ffmpeg will start after
# being killed the first time, so the core command here runs twice after a break.
pkill -P $(pgrep -x screencast\|audio\|video) 2>/dev/null && sleep .5 &&
pkill -P $(pgrep -x screencast\|audio\|video) 2>/dev/null

# Update i3bar.
echo "" > ~/.scripts/.recording
pkill -RTMIN+9 i3blocks