### Install clipaste on clipboard host Source: https://github.com/hqhq1025/clipaste/blob/main/CLAUDE.md Installation commands for macOS, Windows, and source-based builds. ```bash brew install hqhq1025/clipaste/clipaste brew services start clipaste clipaste doctor --json ``` ```powershell irm https://raw.githubusercontent.com/hqhq1025/clipaste/main/install.ps1 | iex clipaste doctor --json ``` ```bash git clone https://github.com/hqhq1025/clipaste.git cd clipaste && cargo build --release ``` -------------------------------- ### Install clipaste on Windows Source: https://github.com/hqhq1025/clipaste/blob/main/docs/index.html Use PowerShell to download and execute the installation script on Windows. ```powershell > irm …/install.ps1 | iex ``` -------------------------------- ### Install clipaste on macOS Source: https://github.com/hqhq1025/clipaste/blob/main/docs/index.html Use Homebrew to install the clipaste binary on macOS systems. ```bash $ brew install hqhq1025/clipaste/clipaste ``` -------------------------------- ### Clipaste CLI Commands Source: https://github.com/hqhq1025/clipaste/blob/main/docs/llms-full.txt List of available commands for managing the Clipaste daemon and environment setup. ```text clipaste Run the daemon (clipboard watcher + HTTP server) clipaste doctor [--json] Diagnose this machine and print the fix command clipaste ssh-setup user@host Configure an SSH remote (add -p PORT for a custom SSH port) clipaste wsl-setup Configure WSL2 (add --host IP to skip host auto-detection) clipaste --version clipaste --help ``` -------------------------------- ### Setup clipaste in WSL2 Source: https://github.com/hqhq1025/clipaste/blob/main/docs/index.html Run this command inside the WSL2 distribution while the clipaste executable is running on the Windows host. ```bash clipaste wsl-setup ``` -------------------------------- ### Diagnostic output example Source: https://github.com/hqhq1025/clipaste/blob/main/docs/llms-full.txt Example of the JSON response returned by the doctor command, indicating system status and specific check results. ```json { "version": "2.4.1", "os": "linux", "role": "ssh-remote", "status": "fail", "checks": [ { "name": "helper", "status": "ok", "detail": "~/.local/bin/clipaste-paste", "fix": null }, { "name": "bridge", "status": "fail", "detail": "http://127.0.0.1:18340 is not answering", "fix": "reconnect: the SSH RemoteForward is only active inside a session opened after ssh-setup" } ] } ``` -------------------------------- ### Configure WSL2 Clipboard Source: https://github.com/hqhq1025/clipaste/blob/main/docs/index.html Run this command inside WSL2 to automatically detect the Windows host and install necessary shims. ```bash $ clipaste wsl-setup [1/2] Locating clipaste on the Windows host... 127.0.0.1 (mirrored-mode loopback) [2/2] Installing xclip/wl-paste shims... OK ``` -------------------------------- ### Check System Status Source: https://github.com/hqhq1025/clipaste/blob/main/docs/index.html Verify the current role and status of the clipaste installation with JSON output. ```json $ clipaste doctor --json { "role": "ssh-remote", "status": "fail", "checks": [ { "name": "helper", "status": "ok", "fix": null }, { "name": "bridge", "status": "fail", "fix": "reconnect: the SSH RemoteForward is only active inside a session opened after ssh-setup" } ] } ``` -------------------------------- ### Run clipaste diagnostics Source: https://github.com/hqhq1025/clipaste/blob/main/CLAUDE.md Use the doctor command to classify the machine, verify the installation status, and receive fix suggestions. ```bash clipaste doctor --json ``` ```json { "version": "2.4.1", "os": "macos", "role": "clipboard-host", "status": "warn", "checks": [ { "name": "daemon", "status": "ok", "detail": "daemon responding on 127.0.0.1:18340", "fix": null }, { "name": "clipboard", "status": "warn", "detail": "no image staged yet — take a screenshot, then re-run doctor", "fix": null } ] } ``` -------------------------------- ### Paste Image in Remote Session Source: https://github.com/hqhq1025/clipaste/blob/main/docs/index.html Use the standard paste shortcut in a new SSH session after completing the setup. ```bash $ claude › why is this test flaky? ^V ▸ [Image #1 attached] ``` -------------------------------- ### Build Clipaste from Source Source: https://github.com/hqhq1025/clipaste/blob/main/docs/llms-full.txt Steps to clone the repository and build the project using Cargo. ```bash git clone https://github.com/hqhq1025/clipaste.git cd clipaste && cargo build --release ``` -------------------------------- ### Build and Test Commands Source: https://github.com/hqhq1025/clipaste/blob/main/CLAUDE.md Standard commands for building the project and running the test suite. ```bash cargo build cargo test # must stay green; no network access required cargo clippy --all-targets ``` -------------------------------- ### Configure WSL2 integration Source: https://github.com/hqhq1025/clipaste/blob/main/CLAUDE.md Run these commands inside the WSL2 distribution to enable clipboard access from the Windows host. ```bash clipaste wsl-setup # probes for the Windows host address clipaste wsl-setup --host 127.0.0.1 # skip probing, use this address ``` -------------------------------- ### Configure clipaste for WSL2 Source: https://github.com/hqhq1025/clipaste/blob/main/docs/llms-full.txt Commands to initialize clipaste within a WSL2 distribution, with an optional flag to manually specify the host address. ```bash clipaste wsl-setup clipaste wsl-setup --host 127.0.0.1 # skip auto-detection ``` -------------------------------- ### Use clipaste-paste helper Source: https://github.com/hqhq1025/clipaste/blob/main/README.md Retrieve the path to a local image file on the remote server. ```bash clipaste-paste # → /tmp/clipaste-.png (a real file on the remote) ``` -------------------------------- ### Execute clipaste Source: https://github.com/hqhq1025/clipaste/blob/main/docs/index.html Standard command to invoke the clipaste utility. ```bash clipaste ``` -------------------------------- ### Manage clipaste on macOS Source: https://github.com/hqhq1025/clipaste/blob/main/README.md Commands for controlling the clipaste service using Homebrew services. ```bash brew services info clipaste # status brew services restart clipaste # restart brew services stop clipaste # stop ``` -------------------------------- ### Project Directory Layout Source: https://github.com/hqhq1025/clipaste/blob/main/CLAUDE.md Overview of the source code organization within the repository. ```text src/ ├── main.rs CLI entry + argument parsing (one parser per subcommand) ├── common.rs version, port, temp-file handling, image conversion, http_get ├── server.rs HTTP server on 127.0.0.1:18340 (/health, /clipboard/type, /clipboard/image) ├── doctor.rs environment classification + checks + human/JSON rendering ├── ssh_setup.rs shim templates, ssh-setup, wsl-setup, host detection ├── macos.rs NSPasteboard watcher (cfg macos) └── windows.rs clipboard-format listener (cfg windows) ``` -------------------------------- ### Run clipaste diagnostics Source: https://github.com/hqhq1025/clipaste/blob/main/docs/index.html Executes system checks and returns results in JSON format, including status and potential fixes. ```bash clipaste doctor --json ``` -------------------------------- ### Manage clipaste on Windows Source: https://github.com/hqhq1025/clipaste/blob/main/README.md Commands for stopping the process and disabling auto-start on Windows. ```powershell taskkill /IM clipaste.exe /F # stop Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Run" -Name "clipaste" # disable auto-start ``` -------------------------------- ### Configure SSH remote access Source: https://github.com/hqhq1025/clipaste/blob/main/CLAUDE.md Run these commands on the clipboard host to configure SSH forwarding for remote sessions. ```bash clipaste ssh-setup user@host # non-interactive; idempotent clipaste ssh-setup user@host -p 22222 # custom SSH port ``` ```bash clipaste doctor --json # role should be "ssh-remote", status "ok" ``` -------------------------------- ### Configure SSH Remote Paste Source: https://github.com/hqhq1025/clipaste/blob/main/README.md Set up the SSH bridge to allow local clipboard access on remote servers. ```bash clipaste ssh-setup user@your-server clipaste ssh-setup user@your-server -p 22222 # custom SSH port ``` -------------------------------- ### Configure SSH Remote Clipboard Source: https://github.com/hqhq1025/clipaste/blob/main/docs/index.html Run this command from the local machine to enable clipboard sharing on a remote SSH host. ```bash $ clipaste ssh-setup dev@build-07 [1/3] Checking local clipaste server... OK [2/3] Installing helper on dev@build-07... OK (Linux) [3/3] Configuring SSH RemoteForward... OK ``` -------------------------------- ### clipaste doctor --json Source: https://github.com/hqhq1025/clipaste/blob/main/docs/llms-full.txt Executes a diagnostic check on the current environment and returns a JSON report detailing the status of system components. ```APIDOC ## CLI Command: clipaste doctor --json ### Description Runs a diagnostic suite to verify the installation and connectivity of the clipaste system. Returns a JSON object containing the system status, version, and specific check results. ### Parameters - **--json** (flag) - Required - Forces the output format to be JSON. ### Response - **version** (string) - The current version of the clipaste tool. - **os** (string) - The detected operating system. - **role** (string) - The detected role (clipboard-host, ssh-remote, or wsl2). - **status** (string) - The overall status (ok, warn, or fail). - **checks** (array) - A list of individual diagnostic checks performed. - **name** (string) - The name of the check. - **status** (string) - The status of the specific check. - **detail** (string) - Additional information regarding the check result. - **fix** (string|null) - A suggested command or instruction to resolve the issue, if applicable. ### Response Example { "version": "2.4.1", "os": "linux", "role": "ssh-remote", "status": "fail", "checks": [ { "name": "helper", "status": "ok", "detail": "~/.local/bin/clipaste-paste", "fix": null }, { "name": "bridge", "status": "fail", "detail": "http://127.0.0.1:18340 is not answering", "fix": "reconnect: the SSH RemoteForward is only active inside a session opened after ssh-setup" } ] } ``` -------------------------------- ### Run diagnostic checks Source: https://github.com/hqhq1025/clipaste/blob/main/README.md Executes a machine classification and diagnostic check, returning a JSON report with potential fixes. ```bash clipaste doctor --json ``` ```json { "version": "2.4.1", "os": "linux", "role": "ssh-remote", "status": "fail", "checks": [ { "name": "helper", "status": "ok", "detail": "~/.local/bin/clipaste-paste", "fix": null }, { "name": "bridge", "status": "fail", "detail": "http://127.0.0.1:18340 is not answering", "fix": "reconnect: the SSH RemoteForward is only active inside a session opened after ssh-setup" } ] } ``` -------------------------------- ### Access Remote Clipboard Source: https://github.com/hqhq1025/clipaste/blob/main/README.md Commands to use after establishing a new SSH session. ```bash ssh user@your-server claude # Ctrl+V pastes screenshots from your local Mac (Linux remote) codex # run `clipaste-paste`, then paste the printed path (see below) ``` -------------------------------- ### Manually Specify Windows Host Address Source: https://github.com/hqhq1025/clipaste/blob/main/README.md Use this command if the automatic host detection fails to identify the correct Windows host address. ```bash clipaste wsl-setup --host 127.0.0.1 ``` -------------------------------- ### Forward Port for NAT Mode Source: https://github.com/hqhq1025/clipaste/blob/main/README.md Execute this in an elevated PowerShell on Windows if NAT mode prevents WSL2 from reaching the clipaste service. ```powershell netsh interface portproxy add v4tov4 listenport=18340 ` listenaddress=(Get-NetIPAddress -InterfaceAlias 'vEthernet (WSL*)' -AddressFamily IPv4).IPAddress ` connectport=18340 connectaddress=127.0.0.1 ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.