Add simple screen recordings (#235)

* Add simple screen recording tool

* Need slurp too
This commit is contained in:
David Heinemeier Hansson
2025-07-18 20:55:28 -07:00
committed by GitHub
parent 3b0fd13be1
commit 2e874adb50
4 changed files with 20 additions and 0 deletions

14
bin/omarchy-screenrecord Executable file
View File

@ -0,0 +1,14 @@
#!/bin/bash
if pgrep -x wl-screenrec >/dev/null; then
pkill -x wl-screenrec
notify-send "Screen recording saved to ~/Videos" -t 2000
else
region=$(slurp) || exit 1
notify-send "Screen recording starting..." -t 1000
sleep 1
wl-screenrec \
-g "$region" \
-f "$HOME/Videos/screen-recording-$(date +'%Y-%m-%d_%H-%M-%S').mp4" \
--ffmpeg-encoder-options="-c:v libx264 -crf 23 -preset medium -movflags +faststart"
fi

View File

@ -28,5 +28,8 @@ bind = , PRINT, exec, hyprshot -m region
bind = SHIFT, PRINT, exec, hyprshot -m window
bind = CTRL, PRINT, exec, hyprshot -m output
# Screenshots
bind = ALT, PRINT, exec, omarchy-screenrecord
# Color picker
bind = SUPER, PRINT, exec, hyprpicker -a

View File

@ -4,5 +4,6 @@ yay -S --noconfirm --needed \
brightnessctl playerctl pamixer wiremix wireplumber \
fcitx5 fcitx5-gtk fcitx5-qt fcitx5-configtool wl-clip-persist \
nautilus sushi ffmpegthumbnailer \
slurp wl-screenrec \
mpv evince imv \
chromium

2
migrations/1752885858.sh Normal file
View File

@ -0,0 +1,2 @@
echo "Install slurp + wl-screenrec for new ALT+PrintScreen screen recorder"
yay -S --noconfirm --needed slurp wl-screenrec