*Epic CLI Manual — [index](../MANUAL.md)*

# 13. `--spool`

```
java -jar java-epic-cli.jar --spool [--pdf|--raw] <file> [printer] [document title]
java -jar java-epic-cli.jar --spool                  # list installed printers
```

Routes a file to a printer by inspecting its **magic bytes**: PDF files are rendered
actual-size through the platform print subsystem; anything else (ZPL label streams, escape
sequences, plain text) is streamed to the printer byte-for-byte as a RAW job.

- With no file argument, installed printers are listed and the system default is marked
  with `*`.
- `[printer]` omitted → system default. `[document title]` labels the queue entry, defaults
  to the file name.
- `--pdf` / `--raw` force the routing instead of magic-byte detection.
- Windows prints RAW via the native spooler (JNA); Linux/macOS via CUPS.
- There is **deliberately no automatic retry** — the caller owns retry policy. The mode
  needs a real print subsystem and is untestable in most sandboxes.
