A tldr client written in Rust
  • Rust 88.9%
  • Roff 7.5%
  • Shell 3.6%
Find a file
Lena Pastwa a8e614d371
Don't suggest tldr --update after an update
When the update happened before trying to display a page, the previous
error message suggested to update again.
2026-03-23 23:16:58 +01:00
.devcontainer feat: add devcontainer configuration 2024-05-13 13:24:00 +05:30
.github build-release: remove needless $() 2026-03-04 03:47:00 +01:00
completions Add --edit and --search to shell completions 2026-03-03 12:50:40 +01:00
src Don't suggest tldr --update after an update 2026-03-23 23:16:58 +01:00
tests Version 1.11.0 2025-03-16 22:21:56 +01:00
.gitattributes chore: bump actions/checkout to v4, update README, add .gitattributes (#45) 2023-10-22 18:49:13 +02:00
.gitignore Improve shell completions (#51) 2023-12-18 23:31:44 +01:00
.mailmap Add .mailmap 2026-03-03 14:43:32 +01:00
build.rs Bump MSRV to 1.88 and use Rust 2024 2026-03-03 14:05:32 +01:00
Cargo.lock Update dependencies 2026-03-21 19:47:34 +01:00
Cargo.toml Update dependencies 2026-03-21 19:47:34 +01:00
LICENSE Update LICENSE 2026-03-03 12:48:40 +01:00
README.md README: mention Debian packages in GitHub Releases 2025-10-01 01:42:41 +02:00
rustfmt.toml Add empty rustfmt.toml to enforce defaults 2023-12-28 04:01:35 +01:00
tldr.1 Update the man page 2026-03-03 15:10:33 +01:00

tlrc

A tldr client written in Rust.

CI release crates.io license
github downloads matrix

screenshot

Installation

Packaging status

Linux/macOS using Homebrew

Install tlrc with Homebrew:

brew install tlrc

Linux/macOS using Nix

Install tlrc from nixpkgs.

Arch Linux

Install tlrc (from source) or tlrc-bin (prebuilt) from the AUR.

openSUSE

Install tlrc with Zypper:

zypper install tlrc

Windows using Winget

Install tlrc with Winget:

winget install tldr-pages.tlrc

Windows using Scoop

Install tlrc with Scoop:

scoop install tlrc

macOS using MacPorts

Install tlrc with MacPorts:

port install tlrc

NetBSD

Install tlrc with pkgin:

pkgin install tlrc

From crates.io

To build tlrc from a source tarball, run:

cargo install tlrc --locked

Note

Shell completion files and the man page will not be installed that way.

From GitHub Releases

You can find prebuilt binaries and Debian packages here.

Usage

See man tldr or the online manpage. For a brief description, you can also run:

tldr --help

Configuration

Tlrc can be customized with a TOML configuration file. To get the default path for your system, run:

tldr --config-path

To generate a default config file, run:

tldr --gen-config > "$(tldr --config-path)"

or copy the below example.

Configuration options

[cache]
# Override the cache directory ('~' will be expanded to your home directory).
dir = "/path/to/cache"
# Override the base URL used for downloading tldr pages.
# The mirror must provide files with the same names as the official tldr pages repository:
# mirror/tldr.sha256sums            must point to the SHA256 checksums of all assets
# mirror/tldr-pages.LANGUAGE.zip    must point to a zip archive that contains platform directories with pages in LANGUAGE
mirror = "https://github.com/tldr-pages/tldr/releases/latest/download"
# Automatically update the cache if it's older than max_age hours.
auto_update = true
# Perform the automatic update after the page is shown (the default is to update first, then show the page).
defer_auto_update = false
max_age = 336 # 336 hours = 2 weeks
# Specify a list of desired page languages. If it's empty, languages specified in
# the LANG and LANGUAGE environment variables are downloaded.
# English is implied and will always be downloaded.
# You can see a list of language codes here: https://github.com/tldr-pages/tldr
# Example: ["de", "pl"]
languages = []

[output]
# Show the title in the rendered page.
show_title = true
# Show the platform name ('common', 'linux', etc.) in the title.
platform_title = false
# Prefix descriptions of examples with hyphens.
show_hyphens = false
# Use a custom string instead of a hyphen.
example_prefix = "- "
# Set the max line length. 0 means to use the terminal width.
# If a description is longer than this value, it will be split
# into multiple lines.
line_length = 0
# Strip empty lines from output.
compact = false
# In option placeholders, show the specified option style.
# Example: {{[-s|--long]}}
# short  : -s
# long   : --long
# both   : [-s|--long]
option_style = "long"
# Print pages in raw markdown.
raw_markdown = false

# Number of spaces to put before each line of the page.
[indent]
# Command name.
title = 2
# Command description.
description = 2
# Descriptions of examples.
bullet = 2
# Example command invocations.
example = 4

# Style for the title of the page (command name).
[style.title]
# Fixed colors:       "black", "red", "green", "yellow", "blue", "magenta", "cyan", "white", "default",
#                     "bright_black", "bright_red", "bright_green", "bright_yellow", "bright_blue",
#                     "bright_magenta", "bright_cyan", "bright_white"
# 256color ANSI code: { color256 = 50 }
# RGB:                { rgb = [0, 255, 255] }
# Hex:                { hex = "#ffffff" }
color = "magenta"
background = "default"
bold = true
underline = false
italic = false
dim = false
strikethrough = false

# Style for the description of the page.
[style.description]
color = "magenta"
background = "default"
bold = false
underline = false
italic = false
dim = false
strikethrough = false

# Style for descriptions of examples.
[style.bullet]
color = "green"
background = "default"
bold = false
underline = false
italic = false
dim = false
strikethrough = false

# Style for command examples.
[style.example]
color = "cyan"
background = "default"
bold = false
underline = false
italic = false
dim = false
strikethrough = false

# Style for URLs inside the description.
[style.url]
color = "red"
background = "default"
bold = false
underline = false
italic = true
dim = false
strikethrough = false

# Style for text surrounded by backticks (`).
[style.inline_code]
color = "yellow"
background = "default"
bold = false
underline = false
italic = true
dim = false
strikethrough = false

# Style for placeholders inside command examples.
[style.placeholder]
color = "red"
background = "default"
bold = false
underline = false
italic = true
dim = false
strikethrough = false

For a style similar to tldr-python-client, add this to your config:

[output]
show_hyphens = true
compact = true

[style]
title.color = "default"
title.bold = true
description.color = "default"
bullet.color = "green"
example.color = "red"
placeholder.color = "default"