demo / network-computer
Public
Copy of github.com/askrobots/network-computer (MIT): a desk you reach from anything. The original lives on GitHub.
GitStable demo
README: say this is a copy and where the original is
cde82c2
14 hours, 4 minutes ago
History
nc-winshot · 420 bytes · 8 lines
| 1 | #!/bin/sh |
| 2 | # nc-winshot TITLE-PART OUT.png: one window, as it is on screen (for docs and sites) |
| 3 | set -e |
| 4 | id=$(xdotool search --onlyvisible --name "$1" | tail -1) |
| 5 | [ -n "$id" ] || { echo "no window like $1" >&2; exit 1; } |
| 6 | eval "$(xdotool getwindowgeometry --shell "$id")" |
| 7 | ffmpeg -hide_banner -loglevel error -y -f x11grab -video_size ${WIDTH}x${HEIGHT} -i "${DISPLAY:-:0}+$X,$Y" -frames:v 1 "$2" |
| 8 | echo "$2 ${WIDTH}x${HEIGHT}" |