Table of Contents
Copas is a lightweight utility for sharing clipboard text data between Linux (Wayland) and Android over a local network. It focuses on doing a few things well, offering a minimal alternative for workflows where simplicity and control matter.
The Purpose of this project is to evolve into a minimal peripheral bridge, allowing an Android device to serve as a seamless clipboard peer, touchpad, and keyboard.
What you need and how to set up Copas on your system.
Copas is written in C++ and built using CMake. If you are using Nix, all dependencies are provided automatically. For manual installation, the following runtime libraries are required:
- GTK 3
- Libayatana AppIndicator
- wl-clipboard
Installing Dependencies
sudo apt install -y libgtk-3-0t64 libayatana-appindicator3-1 wl-clipboardsudo pacman -S --needed gtk3 libayatana-appindicator wl-clipboardsudo dnf install -y gtk3 libayatana-appindicator-gtk3 wl-clipboardTo install the Copas, choose and follow the steps below:
Nix
nix run github:bossearch/copas
# With params
nix run github:bossearch/copas -- --help
- Clone and cd to the git repository.
git clone https://github.com/bossearch/copas.git
cd copas- Enter nix dev shell
nix develop
nix build- Find the binary inside
./result/bin/copas
Add input to your flake.nix:
inputs = {
copas.url = "github:bossearch/copas";
}Enable copas:
{
inputs,
...
}: {
# Add the Home Manager module
imports = [inputs.copas.homeManagerModules.default];
programs.copas = {
enable = true;
# systemd = false;
# settings = {
# port = 6669;
# auth_token = "copas-auto-generated-secret";
# };
};
};
}Manual Installation
-
First make sure to install the necessary dependencies.
-
Download and extract the prebuilt Linux binary from the Release section.
chmod +x copas
./copas --help- You may place the binary to your
$PATH.
sudo cp path/to/copas /usr/local/bin/Build from source
- Clone and cd to the git repository.
git clone https://github.com/bossearch/copas.git
cd copas- Configure and build using CMake.
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build- Install the binary.
sudo cmake --install buildThe copas binary will be installed to /usr/local/bin by default.
Android
The Android client is distributed as a standalone APK.You can install it using Obtainium or download it manually from the Release section.
Note: The Android APK is currently signed with a debug key.
By default, Copas works as a Linux clipboard server and an Android client.
-
When Copas runs for the first time on Linux, it automatically creates a default configuration file at
$XDG_CONFIG_HOME/copas/config.json -
This configuration contains:
- A default TCP port
- An auto-generated authentication token
-
Copas exposes a local HTTP API on the configured port.
-
The Android app connects to the Copas server running on Linux using:
- Linux local IP address
- TCP port
- Authentication token
-
Once connected, you can pull or push clipboard from the android app.
Example config.json:
{
"port": 6669,
"auth_token": "copas-auto-generated-secret"
}Make sure you have TCP port 6669 (or the one selected) opened up in your firewall.
Planned features and future improvements.
- Clipboard sync between Linux and Android
- Cursor control (Android as touchpad)
- Keyboard input from Android
- End to end encryption (TLS/HTTPS)
Distributed under the GPL-3.0-or-later. See LICENSE for more information.