From 5eee5b44924bf9079a67d5bc7612bfad56ddeed3 Mon Sep 17 00:00:00 2001 From: Yaroslav Date: Fri, 17 Jan 2020 19:14:34 +0300 Subject: config restructuring and cleanup --- dotfiles/.local/bin/swayrecord | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100755 dotfiles/.local/bin/swayrecord (limited to 'dotfiles/.local/bin/swayrecord') diff --git a/dotfiles/.local/bin/swayrecord b/dotfiles/.local/bin/swayrecord new file mode 100755 index 0000000..90ed24a --- /dev/null +++ b/dotfiles/.local/bin/swayrecord @@ -0,0 +1,14 @@ +#!/bin/sh + +if [ -f "$HOME/.recordingpid" ]; then + killall -SIGINT wf-recorder + rm -f ~/.recordingpid + notify-send "⏺ Screen recording" "Recording stopped" + killall -39 waybar + exit +fi + +wf-recorder -f "$HOME/Video/recordings/$(date '+%y%m%d-%H%M-%S').mp4" & +echo $! > ~/.recordingpid +notify-send "⏺ Screen recording" "Recording started" +killall -39 waybar -- cgit v1.2.3