Add screc
This commit is contained in:
parent
1827aeaba5
commit
0aa28e44a5
2 changed files with 24 additions and 9 deletions
|
|
@ -1,9 +0,0 @@
|
|||
#!/bin/sh
|
||||
|
||||
echo '{"version":1}'
|
||||
|
||||
echo '['
|
||||
|
||||
echo '[],'
|
||||
|
||||
exec conky -c $1
|
||||
24
home/dot_local/bin/executable_screc
Normal file
24
home/dot_local/bin/executable_screc
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
#!/bin/sh
|
||||
# Take a screen recording in webm format using wf-recorder
|
||||
# The output file is echo'd to stdout and the path copied
|
||||
# using the text/uri-list mimetype to the clipboard.
|
||||
|
||||
|
||||
tmpd=$(mktemp -d -t screc.XXXXXX)
|
||||
outfile="${tmpd}/out.webm"
|
||||
|
||||
geometry=$(slurp)
|
||||
wf-recorder -g "$geometry" -c libvpx -f "$outfile" &>1 /dev/null &
|
||||
recpid=$!
|
||||
|
||||
read -sn1 -p 'Press any key to stop recording:'
|
||||
echo
|
||||
|
||||
kill $recpid
|
||||
echo "$outfile"
|
||||
|
||||
wl-copy -t text/uri-list "file://$outfile"
|
||||
|
||||
(sleep 60 && rm -r $tmpd) &
|
||||
disown
|
||||
|
||||
Loading…
Add table
Reference in a new issue