pkgs/record-screen: hide wf-recorder
This commit is contained in:
parent
048e6a6bb4
commit
f015e9c6fa
|
@ -2,10 +2,10 @@ self:
|
||||||
with self; ''
|
with self; ''
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
RECORDER_PID=$(${procps}/bin/ps aux | ${gnugrep}/bin/grep "\--class screen-recorder" | ${gnugrep}/bin/grep -v grep | ${gawk}/bin/awk '{print $2}')
|
RECORDER_PID=$(${procps}/bin/ps aux | ${gnugrep}/bin/grep "wf-recorder" | ${gnugrep}/bin/grep -v grep | ${gawk}/bin/awk '{print $2}')
|
||||||
NUM_PID=$(echo -n $RECORDER_PID | ${coreutils}/bin/wc -w)
|
NUM_PID=$(echo -n $RECORDER_PID | ${coreutils}/bin/wc -w)
|
||||||
if (( NUM_PID > 0 )); then
|
if (( NUM_PID > 0 )); then
|
||||||
FILE_LOCATION=$(${procps}/bin/ps aux | ${gnugrep}/bin/grep "\--class screen-recorder" | ${gnugrep}/bin/grep -v grep | ${gawk}/bin/awk '{print $NF}')
|
FILE_LOCATION=$(${procps}/bin/ps aux | ${gnugrep}/bin/grep "wf-recorder" | ${gnugrep}/bin/grep -v grep | ${gawk}/bin/awk '{print $NF}')
|
||||||
kill $RECORDER_PID
|
kill $RECORDER_PID
|
||||||
${libnotify}/bin/notify-send "Recorded to $FILE_LOCATION"
|
${libnotify}/bin/notify-send "Recorded to $FILE_LOCATION"
|
||||||
exit 0
|
exit 0
|
||||||
|
@ -21,8 +21,6 @@ with self; ''
|
||||||
RESOLUTION="$(echo $GEOMETRY | ${gawk}/bin/awk '{print $2}')"
|
RESOLUTION="$(echo $GEOMETRY | ${gawk}/bin/awk '{print $2}')"
|
||||||
FILE_LOCATION="$HOME/Videos/Screenrecordings/$(${coreutils}/bin/date +%Y%m%d_%Hh%Mm%Ss)_$RESOLUTION.mp4"
|
FILE_LOCATION="$HOME/Videos/Screenrecordings/$(${coreutils}/bin/date +%Y%m%d_%Hh%Mm%Ss)_$RESOLUTION.mp4"
|
||||||
echo "Recording $GEOMETRY into $FILE_LOCATION"
|
echo "Recording $GEOMETRY into $FILE_LOCATION"
|
||||||
${alacritty}/bin/alacritty \
|
${wf-recorder}/bin/wf-recorder -g "$GEOMETRY" -f "$FILE_LOCATION"
|
||||||
--class screen-recorder \
|
|
||||||
-e ${wf-recorder}/bin/wf-recorder -g "$GEOMETRY" -f "$FILE_LOCATION"
|
|
||||||
${libnotify}/bin/notify-send "Recording to $FILE_LOCATION"
|
${libnotify}/bin/notify-send "Recording to $FILE_LOCATION"
|
||||||
''
|
''
|
||||||
|
|
Loading…
Reference in a new issue