rfc
A command-line tool to search, retrieve, and display IETF RFCs and Internet-Drafts.
Features
- View RFCs and Internet-Drafts - fetch and display documents in your preferred viewer
- Search - query the IETF Datatracker by keyword
- Local caching - documents are cached for offline access and faster repeat reads
- Format conversion - falls back to HTML and converts to plain text when no .txt is published
Installation
Requires Rust. If you don't have it, see rustup.rs.
From crates.io:
The installed binary is named rfc.
From source:
Usage
The default command, rfc <document>, looks in the local cache first and only hits the network on a miss. Everything else lives under a subcommand.
View a document
Pick a viewer
By default the document opens in $EDITOR, then $PAGER, then nothing. Override with -o:
The document is written to a tempfile and the viewer is invoked with the path as its final argument - works for editors and pagers alike.
Open in web browser instead of viewing locally:
Refresh from the API
There's no --refresh flag. To force a re-fetch, run rfc fetch then rfc <doc>:
Search
Cache management
Cache location
- Linux:
~/.cache/rfc/ - macOS:
~/Library/Caches/rfc/ - Windows:
{FOLDERID_LocalAppData}\rfc\cache\
Each document is stored with its content (.txt) and a metadata sidecar (.meta) holding the title.
License
BSD-3-Clause