Skip to content

labi-le/belphegor

Repository files navigation

belphegor

Belphegor is a clipboard manager that allows you to share your clipboard with other devices on the network


Features

  • Encryption
  • P2P
  • Discovering local nodes
  • Image sharing
  • File sharing

Dependencies

  • linux:

    • wayland
      • composer implements ext_data_control_v1 (sway, kde, etc)
      • wl-clipboard
    • X11
      • XFixes
  • macos:

    • 12 or newer
  • windows:

    • 10 or newer (may work on older versions)

Installation

  • Prebuilt binaries

  • Nix flake

    as profile
    nix profile install github:labi-le/belphegor
    import the module
    {
      # inputs
      belphegor.url = "github:labi-le/belphegor";
      # outputs
      overlay-belphegor = final: prev: {
        belphegor = belphegor.packages.${system}.default;
      };
    
      modules = [
        ({ config, pkgs, ... }: { nixpkgs.overlays = [ overlay-belphegor ]; })
      ];
    
      # add package
      environment.systemPackages = with pkgs; [
        belphegor
      ];
    }
  • windows
    irm https://raw.githubusercontent.com/labi-le/belphegor/refs/heads/main/install.ps1 | iex

Build from source

  • Go 1.26
  • git
  • makefile
git clone https://github.com/labi-le/belphegor.git
cd belphegor
make build

Usage

  -c, --connect string            Address in ip:port format to connect to the node
       --discover_delay duration   Delay between node discovery (default 5m0s)
       --file_save_path string     Folder where the files sent to us will be saved (default: Tmp dir)
   -h, --help                      Show help
       --hidden                    Hide console window (for windows user) (default true)
       --install_service           Install systemd-unit and start the service
       --keep_alive duration       Interval for checking connections between nodes (default 1m0s)
       --allow_copy_files          Allow to copy files (default true)
       --max_clipboard_files int   Maximum number of files that can be copied (and announced) in a single copy operation (default 10)
       --max_file_size string      Maximum file size to receive (default "500MiB")
       --max_peers int             Maximum number of discovered peers (default 5)
       --node_discover             Find local nodes on the network and connect to them (default true)
       --notify                    Enable notifications (default true)
   -p, --port int                  Port to use. Default: random
       --read_timeout duration     Write timeout (default 1m0s)
       --secret string             Key to connect between node (empty=all may connect)
       --transport string          Transport protocol: quic, tcp (default "quic")
       --verbose                   Verbose logs
   -v, --version                   Show version
       --write_timeout duration    Write timeout (default 1m0s)

Autostart

sway
exec belphegor
systemd service to install service, you need to have PATH in current ENV, otherwise the notifications will not work
belphegor --install-service

uninstall

systemctl --user disable --now belphegor

Limitations

  • the app can't work properly on gnome
  • when files are copied to the windows clipboard, the file paths aren't copied; the files themselves are downloaded successfully, but they cannot be pasted

Todo

[x] Create github actions for build binary and running tests

[x] Add flake

[x] Add x11 support

[] Upnp (?)

[] Android app or magisk module (?)

About

Sharing the clipboard between your computers

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors