blob: f00f84ccb61e18f15c5d295fa8f02c9d760dd03d (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
|
#!/usr/bin/env sh
# zbarcam opens an X11 preview window, so DISPLAY must reach XWayland.
# Fall back to :0 (sway's default XWayland display) if it's missing.
export DISPLAY="${DISPLAY:-:0}"
text="$(zbarcam -q -1 --raw)"
printf '%s' "$text" | wl-copy
echo "$text"
notify-send "$text"
|