-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Wayland watcher prototype implementation
- Loading branch information
Alex Saveau
committed
Nov 30, 2024
1 parent
ba8edcb
commit 7368ac1
Showing
8 changed files
with
680 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,6 +7,7 @@ members = [ | |
"server", | ||
"tui", | ||
"watcher-utils", | ||
"wayland", | ||
"wayland-interface-check", | ||
"x11", | ||
] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
[package] | ||
name = "clipboard-history-wayland" | ||
version.workspace = true | ||
authors.workspace = true | ||
edition.workspace = true | ||
description = "Wayland Ringboard clipboard listener." | ||
repository.workspace = true | ||
keywords = ["ringboard", "clipboard", "tools", "wayland"] | ||
categories = ["command-line-utilities", "development-tools", "filesystem"] | ||
license.workspace = true | ||
|
||
[dependencies] | ||
env_logger = { version = "0.11.5", default-features = false } | ||
error-stack = { version = "0.5.0", default-features = false, features = ["std"] } | ||
log = { version = "0.4.22", features = ["release_max_level_info"] } | ||
ringboard-sdk = { package = "clipboard-history-client-sdk", version = "0", path = "../client-sdk", features = ["error-stack", "config"] } | ||
ringboard-watcher-utils = { package = "clipboard-history-watcher-utils", version = "0", path = "../watcher-utils" } | ||
rustc-hash = "2.0.0" | ||
rustix = { version = "0.38.41", features = ["pipe"] } | ||
thiserror = "2.0.3" | ||
wayland-client = "0.31.7" | ||
wayland-protocols-wlr = { version = "0.3.5", features = ["client"] } | ||
|
||
[features] | ||
default = ["human-logs"] | ||
human-logs = ["env_logger/default"] | ||
|
||
[[bin]] | ||
name = "ringboard-wayland" | ||
path = "src/main.rs" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../LICENSE-APACHE |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# Ringboard Wayland | ||
|
||
<a href="https://crates.io/crates/clipboard-history-wayland">![Crates.io Version](https://img.shields.io/crates/v/clipboard-history-wayland)</a> | ||
|
||
This binary provides a Wayland clipboard watching service for the Ringboard database. It connects to | ||
the Wayland and Ringboard servers and uses the `ext_data_control_v1` protocol to monitor the | ||
clipboard for new clipboard selections to send to the Ringboard server. | ||
|
||
Additionally, it offers a paste server capable of becoming the Wayland selection owner for clients | ||
to call. Implementation notes are similar to the [X11 watcher](../x11). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
[Unit] | ||
Description=Wayland Ringboard clipboard listener | ||
Documentation=https://github.com/SUPERCILEX/clipboard-history | ||
Requires=ringboard-server.service | ||
After=ringboard-server.service | ||
BindsTo=graphical-session.target | ||
After=graphical-session.target | ||
|
||
[Service] | ||
Type=exec | ||
Environment=RUST_LOG=trace | ||
ExecStart=ringboard-wayland | ||
Restart=on-failure | ||
Slice=ringboard.slice | ||
|
||
[Install] | ||
WantedBy=graphical-session.target |
Oops, something went wrong.