blob: 068a1995bc94d161527ab89c47eca048e40d3048 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
#!/bin/sh
set -e
if [ -n "$1" ]; then
printf "usage: %s\n" "$(basename "$0")"
printf "\n"
printf "launches wayvnc(1), wshowkeys(1) and remmina(1)\n"
exit 2
fi
server_args=
if [ -n "$OUTPUT" ]; then
server_args="-o ${OUTPUT}"
fi
trap '{ printf "\n=> killing everything...\n"; pkill wayvnc; pkill gvncviewer; }' EXIT
# echo "=> starting wshowkeys"
# swaymsg exec "wshowkeys -a bottom -a left -F 'Iosevka Sparkle 25' -t 1" >/dev/null
echo "=> starting wayvnc"
swaymsg exec "wayvnc -c dmabuf -r ${server_args} 0.0.0.0" >/dev/null
echo "=> starting viewer"
swx -b none -S -F '1.0 tl' -- x11fy gvncviewer localhost
notify-send 'started screensharing' 'the vnc viewer window was moved to the scratchpad'
while true; do
sleep $((1024*1024))
done
|