CLI Command Reference

The hayate binary provides a CLI for encrypted peer-to-peer LAN transfers. All subcommands support --help for live documentation.


hayate receive

Starts a receiver that listens for incoming file or directory transfers. Runs until interrupted or a transfer completes.

Usage: hayate receive [OPTIONS]

Options

FlagDescriptionDefault
-b, --bind <IP>Local IP to bind the QUIC listener0.0.0.0
-p, --port <PORT>UDP port to listen on50001
-o, --output <DIR>Directory to save received files into.
--auto-acceptAccept all transfers without promptingfalse
--code <PHRASE>Pairing-code phrase for mDNS + UDP discoverynone
--no-progressDisable the progress barfalse

Examples

# Listen on port 50002, save to ~/Downloads
hayate receive --port 50002 --output ~/Downloads

# Pairing mode with auto-accept — no prompts
hayate receive --code "cherry-blossom-spring" --auto-accept

Environment variables

VariableEffect
HAYATE_BINDDefault for --bind
HAYATE_PORTDefault for --port
NO_COLORDisables styled terminal output

hayate send

Transmits a file or directory to a receiver. Uses either direct addressing or pairing-code discovery.

Usage: hayate send [OPTIONS] <PATH> [TARGET]

Positional arguments

ArgDescription
PATHFile or directory to send
TARGETReceiver address as ip:port or hostname:port

Options

FlagDescriptionDefault
--peer <ADDR>Equivalent to positional TARGETnone
--code <PHRASE>Pairing code for LAN discoveryauto-generated
-z, --compressZstd compression (level 1)true
--hash <ALGO>Integrity algorithm: blake3, rapidhash, sha256blake3
--no-progressDisable progress barfalse

Examples

# Direct transfer to a known receiver
hayate send ./photos 192.168.1.50:50001

# Pairing-mode with a shared code phrase
hayate send report.pdf --code "alpha-bravo-charlie-delta"

# Fast path: rapidhash integrity with compression off
hayate send large-dataset.bin 10.0.0.5:50001 --hash rapidhash --compress=false

hayate discover

Scans the local network for active Hayate receivers using high-concurrency QUIC probes.

Usage: hayate discover [OPTIONS]

Options

FlagDescriptionDefault
-t, --timeout <SECS>Scan timeout in seconds15
--cidr <RANGE>Subnet CIDR to scan (e.g. 192.168.1.0/24)auto-detected

Examples

# Scan all detected subnets
hayate discover

# Scan a specific /24 subnet with a custom timeout
hayate discover --cidr 10.0.0.0/24 --timeout 10

How it works

discover probes every host in the target subnet(s) with a QUIC handshake, measuring round-trip time. Results stream live as peers respond — you don't wait for the full scan. Priority hosts (gateways: .1-.3, .253-.254) are probed first.