Skip to content

Commit fa3be66

Browse files
authored
Merge pull request #26 from devmobasa/feat/xdg-gnome-fallback
Feat/xdg gnome fallback
2 parents 3e79cc2 + 7a60f88 commit fa3be66

File tree

20 files changed

+875
-154
lines changed

20 files changed

+875
-154
lines changed
Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,107 @@
1+
name: Build Linux Packages
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
tags:
7+
- "v*"
8+
9+
jobs:
10+
package:
11+
runs-on: ubuntu-latest
12+
strategy:
13+
matrix:
14+
format: [deb, rpm]
15+
permissions:
16+
contents: read
17+
steps:
18+
- name: Checkout
19+
uses: actions/checkout@v4
20+
21+
- name: Install build dependencies
22+
run: |
23+
sudo apt-get update
24+
sudo apt-get install -y \
25+
build-essential \
26+
pkg-config \
27+
libwayland-dev \
28+
libxkbcommon-dev \
29+
libcairo2-dev \
30+
libpango1.0-dev \
31+
libgtk-3-dev \
32+
libssl-dev \
33+
libxcb-shape0-dev \
34+
libxcb-xfixes0-dev \
35+
libxcb-render0-dev \
36+
libxcb1-dev \
37+
libx11-dev
38+
39+
- name: Set up Rust
40+
uses: dtolnay/rust-toolchain@stable
41+
42+
- name: Install nfpm
43+
run: |
44+
NFPM_VERSION=2.43.4
45+
curl -sSfL "https://github.com/goreleaser/nfpm/releases/download/v${NFPM_VERSION}/nfpm_${NFPM_VERSION}_Linux_x86_64.tar.gz" \
46+
| tar -xz nfpm
47+
sudo mv nfpm /usr/local/bin/
48+
nfpm --version
49+
50+
- name: Cache cargo
51+
uses: Swatinem/rust-cache@v2
52+
with:
53+
workspaces: |
54+
.
55+
configurator
56+
57+
- name: Build release binaries
58+
env:
59+
CARGO_TARGET_DIR: target
60+
run: |
61+
cargo build --release --bins
62+
cargo build --release --bins --manifest-path configurator/Cargo.toml
63+
strip target/release/wayscriber
64+
strip target/release/wayscriber-configurator
65+
66+
- name: Read crate version
67+
id: meta
68+
run: |
69+
VERSION=$(cargo metadata --no-deps --format-version 1 | jq -r '.packages[] | select(.name=="wayscriber") | .version')
70+
echo "version=${VERSION}" >> "$GITHUB_OUTPUT"
71+
72+
- name: Build ${{ matrix.format }} package
73+
env:
74+
VERSION: ${{ steps.meta.outputs.version }}
75+
run: |
76+
mkdir -p dist
77+
nfpm pkg --packager ${{ matrix.format }} --config packaging/package.yaml --target dist/
78+
if [ "${{ matrix.format }}" = "deb" ]; then
79+
mv dist/*.deb dist/wayscriber-amd64.deb
80+
# To restore versioned + stable artifacts, switch back to copying instead of moving.
81+
else
82+
mv dist/*.rpm dist/wayscriber-x86_64.rpm
83+
# To restore versioned + stable artifacts, switch back to copying instead of moving.
84+
fi
85+
86+
- name: Upload artifact
87+
uses: actions/upload-artifact@v4
88+
with:
89+
name: wayscriber-${{ steps.meta.outputs.version }}-${{ matrix.format }}
90+
path: dist/*.${{ matrix.format }}
91+
92+
release:
93+
needs: package
94+
runs-on: ubuntu-latest
95+
permissions:
96+
contents: write
97+
steps:
98+
- name: Download packaged artifacts
99+
uses: actions/download-artifact@v4
100+
with:
101+
path: dist
102+
103+
- name: Publish GitHub release (auto notes)
104+
uses: softprops/action-gh-release@v2
105+
with:
106+
files: dist/**/*
107+
generate_release_notes: true

README.md

Lines changed: 56 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# wayscriber
22

3-
> TL;DR: wayscriber is a ZoomIt-like screen annotation tool for Wayland compositors, written in Rust.
4-
> Works on compositors with the wlr-layer-shell protocol (Hyprland, Sway, river, …); building from source requires Rust 1.85+.
3+
> TL;DR: wayscriber is a ZoomIt-like screen real-time annotation tool for Linux, written in Rust.
4+
> Building from source requires Rust 1.85+.
55
> Quick start: [set it up in four steps](#quick-start).
66
77
<details>
@@ -35,21 +35,44 @@ https://github.com/user-attachments/assets/7c4b36ec-0f6a-4aad-93fb-f9c966d43873
3535
- [Contributing & Credits](#contributing--credits)
3636

3737
## Why wayscriber?
38-
39-
- Works across Wayland compositors (Sway, Wayfire, River, Hyprland, …) via wlr-layer-shell. Tested extensively on Hyprland and confirmed working on Niri; reports from other compositors welcome.
40-
- Built for live presentations, classroom sessions, and screenshares - toggle with a key and annotate your screen instantly without breaking flow.
38+
- Annotate live over any app/window on any monitor; the overlay floats above without rearranging your workspace.
39+
- Use shapes, arrows, and text to explain steps, give demos, or build quick guides.
40+
- Redact/hide parts of the screen and grab screenshots (region, active window, fullscreen) in one keypress.
41+
- Toggle instantly from a lightweight background daemon when you need it.
42+
- Persist per-monitor/per-board canvases and tool state so your setup comes back after restarts.
43+
- Presenter helpers: click highlights and “freeze screen” to pause what viewers see while apps keep running.
44+
- Works on wlr-layer-shell compositors (Plasma KDE/KWin, Hyprland, Sway, Wayfire, River, …) with an xdg fallback for GNOME.
45+
- Real-hardware tests where it works:
46+
- Ubuntu 25.10 GNOME (xdg fallback)
47+
- Fedora 43 KDE (Plasma, layer-shell)
48+
- Fedora 43 GNOME (xdg fallback)
49+
- Debian 13.2 KDE (Plasma, layer-shell)
50+
- Debian 13.2 GNOME (xdg fallback)
51+
- CachyOS 2025-August KDE (Plasma, layer-shell)
52+
- Hyprland on Arch (layer-shell)
53+
- Niri on Arch (layer-shell)
4154
- Complements tools like [Satty](https://github.com/gabm/Satty): Satty excels at capture → annotate → save workflows, while wayscriber stays resident as an always-available drawing layer with instant mode switching.
4255

4356
## Quick Start
4457

4558
**1. Install wayscriber**
46-
1. Arch Linux (AUR): (build from source)
47-
- `yay -S wayscriber`
48-
- `paru -S wayscriber`
49-
2. Arch Linux (AUR, prebuilt):
50-
- `yay -S wayscriber-bin`
51-
- `paru -S wayscriber-bin`.
52-
3. Other distros: see [Installation](#installation), then install `wl-clipboard`, `grim`, and `slurp` for the fastest screenshot workflow.
59+
1. Debian/Ubuntu (latest release):
60+
- Download & install:
61+
```bash
62+
wget -O wayscriber-amd64.deb https://github.com/devmobasa/wayscriber/releases/latest/download/wayscriber-amd64.deb
63+
sudo apt install ./wayscriber-amd64.deb
64+
```
65+
_Note: apt may print “Download is performed unsandboxed as root …” when installing a local file; this is expected._
66+
2. Fedora/RHEL (latest release):
67+
- Download & install:
68+
```bash
69+
wget -O wayscriber-x86_64.rpm https://github.com/devmobasa/wayscriber/releases/latest/download/wayscriber-x86_64.rpm
70+
sudo rpm -Uvh wayscriber-x86_64.rpm
71+
```
72+
3. Arch Linux (AUR):
73+
- `yay -S wayscriber` (source) or `paru -S wayscriber`
74+
- `yay -S wayscriber-bin` (prebuilt) or `paru -S wayscriber-bin`
75+
4. Other distros: see [Installation](#installation), then install `wl-clipboard`, `grim`, and `slurp` for the fastest screenshot workflow.
5376

5477
**2. Choose how to run it:**
5578

@@ -99,6 +122,7 @@ bind = SUPER, D, exec, pkill -SIGUSR1 wayscriber
99122
- **Board modes**: Whiteboard, blackboard, and transparent overlays, each with isolated frames and auto pen contrast; snap back to transparent with `Ctrl+Shift+T`.
100123
- **Capture shortcuts**: Full-screen saves, active-window grabs, and region capture to file or clipboard using `grim`, `slurp`, and `wl-clipboard` when available.
101124
- **Session persistence**: Opt-in per board/monitor storage that restores your canvas plus pen color & thickness; inspect with `wayscriber --session-info` or clear with `wayscriber --clear-session`.
125+
- **Freeze / pause view**: Toggle freeze to pause what viewers see while your apps keep running; hotkey `Ctrl+Shift+F` or start frozen with `wayscriber --freeze`.
102126
- **Workflow helpers**: Background daemon with SIGUSR1 toggle, tray icon, one-shot mode, live status bar, and in-app help overlay (`F10`).
103127
- **Context menus & selection**: Right-click or press `Shift+F10` for per-shape actions (delete, duplicate, layer order, lock/unlock, properties) with keyboard navigation and selection halos for clarity.
104128
- **Click highlights**: Presenter-style halo on mouse clicks with configurable colors, radius, and duration; follows your pen color by default, toggle the effect with `Ctrl+Shift+H` or swap to highlight-only mode with `Ctrl+Alt+H`.
@@ -130,6 +154,21 @@ https://github.com/user-attachments/assets/7c4b36ec-0f6a-4aad-93fb-f9c966d43873
130154

131155
See **[docs/SETUP.md](docs/SETUP.md)** for detailed walkthroughs.
132156

157+
### GitHub release packages (Debian/Ubuntu & Fedora/RHEL)
158+
159+
Use the stable filenames from the latest release:
160+
161+
```bash
162+
# Debian/Ubuntu
163+
wget -O wayscriber-amd64.deb https://github.com/devmobasa/wayscriber/releases/latest/download/wayscriber-amd64.deb
164+
sudo apt install ./wayscriber-amd64.deb
165+
# Note: apt may print “Download is performed unsandboxed as root …” when installing a local file; this is expected.
166+
167+
# Fedora/RHEL
168+
wget -O wayscriber-x86_64.rpm https://github.com/devmobasa/wayscriber/releases/latest/download/wayscriber-x86_64.rpm
169+
sudo rpm -Uvh wayscriber-x86_64.rpm
170+
```
171+
133172
### Arch Linux (AUR)
134173

135174
```bash
@@ -148,24 +187,19 @@ paru -S wayscriber-bin
148187

149188
The package installs the user service at `/usr/lib/systemd/user/wayscriber.service`.
150189

151-
> **Upgrading from the old `hyprmarker` packages?**
152-
> Remove the legacy packages once and reinstall under the new name:
153-
> ```bash
154-
> sudo pacman -Rns hyprmarker hyprmarker-debug # ignore if either package is already gone
155-
> yay -S wayscriber # or yay -S wayscriber-bin
156-
> ```
157-
> After this one-time cleanup, future upgrades work exactly like any other AUR package.
158190

159191
### Other Distros
160192

161193
**Install dependencies:**
162194

195+
Ubuntu / Debian:
163196
```bash
164-
# Ubuntu / Debian
165197
sudo apt-get install libcairo2-dev libwayland-dev libpango1.0-dev
198+
```
166199

167-
# Fedora
168-
sudo dnf install cairo-devel wayland-devel pango-devel
200+
Fedora:
201+
```bash
202+
sudo dnf install gcc gcc-c++ make pkgconf-pkg-config cairo-devel wayland-devel pango-devel libxkbcommon-devel cairo-gobject-devel
169203
```
170204

171205
Optional but recommended for screenshots:

config.example.toml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,13 @@ show_status_bar = true
108108
# Options: "top-left", "top-right", "bottom-left", "bottom-right"
109109
status_bar_position = "bottom-left"
110110

111+
# Preferred monitor for GNOME fallback (xdg-shell) overlay. Case-insensitive match
112+
# against monitor identity; leave empty to use the current/first monitor.
113+
#preferred_output = "eDP-1"
114+
115+
# Request fullscreen for the GNOME fallback overlay. Disable if fullscreen appears opaque.
116+
#xdg_fullscreen = false
117+
111118
# ───────────────────────────────────────────────────────────────────────────────
112119
# Status Bar Styling
113120
# ───────────────────────────────────────────────────────────────────────────────

0 commit comments

Comments
 (0)