Adds LocalSend-compatible text messaging alongside file transfer. Wire format (matches the LocalSend app): a message is a single "file" with fileType "text/plain" whose content rides in the prepare-upload `preview` field. The receiver returns an empty token set, so nothing is uploaded — the text is read straight from the preview. - client: SendMessage builds that single-file prepare-upload (no body upload). - server: detect a message (one text file with non-empty preview), surface it on a new Messages() channel instead of saving a file, and respond with an empty file set. Messages bypass the accept prompt (auto-received); the PIN gate still applies. - app: bridge the server's messages channel to the TUI as MessageMsg. - tui: a new Messages tab lists received messages (enter to read full, d to delete); press `m` on a device to compose and send one. Incoming messages show a footer notice. Tests: end-to-end send→receive (text intact, sender preserved, nothing written to disk) and unit coverage of the message-detection rule. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| cmd/omarchy-send | ||
| dist | ||
| internal | ||
| .gitignore | ||
| go.mod | ||
| go.sum | ||
| install.sh | ||
| LICENSE | ||
| README.md | ||
Omarchy-Send (omarchy-send)
A LocalSend-compatible file-transfer client with a terminal UI, built for headless Arch / Omarchy servers used over SSH — no desktop environment, no clipboard, no browser. It interoperates with the stock LocalSend mobile and desktop apps on the same LAN, including their default encrypted (HTTPS) mode.
Features
- Discovery — multicast announce/listen on
224.0.0.167:53317plus the HTTP/registerhandshake, with peer aging. - Receive — incoming files are accepted via a prompt (or auto-accepted) and written to the receive directory, with live progress.
- Send — pick a peer, stage files (or whole folders) with a built-in file picker, and upload them with progress, rate and ETA. Folders are sent recursively with their structure preserved on the receiver.
- Messages — send a plain-text message to a peer (LocalSend-compatible) and read messages others send you in a dedicated Messages tab.
- Manage — browse the receive folder, mark received files (or whole folders) and delete the ones you no longer want, behind a confirmation prompt.
- HTTPS — generates a self-signed certificate whose fingerprint matches the scheme the official client pins (uppercase-hex SHA-256 of the cert DER), so stock encrypted peers talk to it with no configuration.
- Single static binary, pure-stdlib protocol layer; only the Charm TUI libraries are external dependencies.
Install
One line, nothing to clone:
curl -fsSL https://raw.githubusercontent.com/28allday/omarchy-send/main/install.sh | bash
This downloads the right binary for your architecture into ~/.local/bin, and on
Omarchy also adds a floating Walker entry (search Omarchy-Send). Override the
location with BIN_DIR=/usr/local/bin, or pin a version with
OMARCHY_SEND_VERSION=v0.1.0.
The installer is a short shell script fetched over HTTPS; read it first if you prefer — it lives at
install.shin this repo.
Build from source
git clone https://github.com/28allday/omarchy-send
cd omarchy-send
go build -o omarchy-send ./cmd/omarchy-send # or: ./install.sh
Run from a clone, ./install.sh builds with your local Go toolchain instead of
downloading.
Usage
omarchy-send # uses config / sensible defaults
omarchy-send --alias my-server # override the advertised device name
omarchy-send --port 53317 # override the listen port
omarchy-send --dir ~/Downloads # override the receive directory
omarchy-send --auto-accept # accept incoming transfers without a prompt
omarchy-send --pin 2468 # require senders to supply this PIN
omarchy-send --no-icons # drop Nerd Font glyphs (non-Nerd-Font terminals)
Theming
On Omarchy, the TUI reads the active theme's ~/.config/omarchy/current/theme/colors.toml
and matches it. Elsewhere (headless / over SSH) it falls back to ANSI palette
colours, so it tracks whatever colour scheme the connecting terminal uses.
Device name
On first run, each device is given a random, friendly display name such as
"Crimson Quasar" (a colour + a celestial object), generated once and saved.
This avoids broadcasting your machine's hostname to everyone on the network —
handy on a laptop joining untrusted Wi-Fi. The hostname is still carried in the
device-model field, and you can set any name you like with --alias or the e
key in the Settings tab.
Config (including the generated TLS identity) is stored at
~/.config/omarchy-send/config.json. Received files default to ~/Omarchy-Send/.
Unattended / headless mode
For a server that should accept files without anyone at the keyboard, combine auto-accept with a PIN so only senders who know the code can push to it:
omarchy-send --auto-accept --pin 2468
Keys
1–5ortab— switch between Devices / Transfers / Manage / Messages / Settings- Peers:
entersend to the selected peer ·mmessage the selected peer ·rrefresh ·/filter - Send picker:
enterstage a file ·aadd the current folder ·backspaceunstage ·Ssend ·escback - Incoming prompt:
yaccept ·nreject - Transfers:
cclear finished - Messages:
enterread the full message ·ddelete it (incoming messages arrive automatically, with a footer notice) - Manage:
spacemark file/folder ·amark all ·ddelete marked (or the one under the cursor) ·rrefresh ·/filter — deletion asks to confirm first - Settings:
eedit (alias / receive dir / PIN) ·atoggle auto-accept - Sending to a PIN-protected peer prompts for the PIN and retries
qquit
Debugging
Set OMARCHY_SEND_LOG=/path/to/log to record discovery/transfer events to a file.
Notes on iOS
iOS LocalSend decides whether received media lands in the Photo Library based on its own in-app settings; its post-receive "open file" prompt can fail to open files from the app cache. Both behaviours occur identically with the official desktop client and are not controlled by the sender.
License
MIT — see LICENSE. Omarchy-Send is an independent implementation of the published LocalSend protocol; it is not affiliated with the LocalSend project. The terminal UI is built on the Charm libraries (also MIT).