Extract stats and clipboard helpers

This commit is contained in:
David Heinemeier Hansson
2026-05-21 11:58:43 +02:00
parent 8734464439
commit 4cd23d9584
7 changed files with 109 additions and 56 deletions
+20
View File
@@ -0,0 +1,20 @@
#!/bin/bash
# omarchy:summary=Copy a file to the clipboard and paste it
# omarchy:group=clipboard
# omarchy:args=<mime-type> <path>
# omarchy:examples=omarchy clipboard paste file image/png /tmp/screenshot.png
mime=${1:-}
path=${2:-}
if [[ -z $mime || -z $path ]]; then
echo "Usage: omarchy-clipboard-paste-file <mime-type> <path>" >&2
exit 1
fi
[[ -r $path ]] || exit 1
wl-copy --type "$mime" < "$path"
sleep 0.15
wtype -M shift -k Insert -m shift 2>/dev/null || true