Tldr-pages Keeps It Short, Wherever You Need It

Let’s face it, even the most accomplished console cowboy can’t keep everything memorized. Sure, you might know all the important arguments for a daily-use tool like tar or ls, but what about the commands you don’t use that often? For that matter, even if you do use tar every day, we bet you don’t know all of the options it supports.

Built-in documentation or the man pages are of course a huge help, but they are dense resources. Sometimes what you really need is to see just a few key examples. When that happens, check out the tldr-pages project and its array of front-ends. Whether you’re working remotely on an embedded gadget, or have the luxury of a full desktop OS and browser, the project offers a way to get the help you need as quickly as possible.

The idea behind the project is that you can provide the command or tool you want to know more about, and instantly see a list of common options it takes. You’ll also be provided a realistic example for each one, which can often help make things “click” when you’re looking at a particularly obtuse utilization.

If you’re working on a box that has Python, getting access to the database of commands and examples is as simple as running pip3 install tldr and giving it a command you want to learn more about:

There’s also a very slick browser client which can be installed as a progressive web app (PWA) for off-line use. You can even embed it into your own web pages, like so:

If none of that tickles your fancy, the entire database is offered up as a PDF for your local perusal — don’t worry, it only clocks in at around 6 MB.

No matter how you access it, tldr-pages offers up a wealth of practical command line knowledge. Whether you’re looking to hone your terminal skills, or perhaps want to submit your own examples for the benefit of the community, this is definitely a project to keep in mind.

Thanks to [abrakadabra] for the tip.

16 thoughts on “Tldr-pages Keeps It Short, Wherever You Need It

  1. While I think this is super cool, I think this is simply a documentation issue with Linux based distos.

    On FreeBSD the man pages already have this in the examples section. You can go directly to the example section with ‘/^Example’ in the terminal pager.

  2. Love it, great for Rpi. Don’t have to switch to desktop to get example of command.
    Installed it and once did tldr -p Linux to download Linux examples.
    From then on just type the request.
    ie: tldr su

  3. Another option is to use an AI CHAT bot at command line to query exactly what you want.
    I just do this:
    $ g “hello how are you gemini ai?”
    $ g “Tell me how to do silent for curl?”
    curl -s or curl –silent

    I know all these commands with lots of command flags, mind boggling to remember them all.

  4. I just recently found this set of tools. Really is a gamechanger. Only difference is that I use cheat.sh instead of tldr, but it includes all the pages from tldr and other sources.

    Other thing I did was bind cheat.sh in my .bash_aliases:

    cheatsheet for commands

    function cheat() {
    curl cheat.sh/$1
    }

    Makes it very useful when you know what command you want at the terminal, so I just run “cheat rsync”, (as an example) and that lets me quickly scan the examples rather than having to read the manpages.

    1. Wow! I like this!

      I recently switched to Fish shell. I don’t really know it very well yet and had to look up how to do this. So for anyone in a similar situation…

      Just type out the function to define it in the current session.

      function cheat
      curl cheat.sh/$argv[1]
      end

      Then the command
      funcsave cheat

      That automatically creates a script and saves it in your .config/fish/functions/ directory so you don’t have to do it again.

      Sure, you could have looked this up yourself but giving it away seemed to be in the spirit of what we are talking about.

  5. If every manpage had a section like this at the top where the ‘common’ stuff could be quickly found then the full version with all the minutia could be listed below… maybe there would be a lot less RTFM responses required out there on the internet.

  6. I use local AI for this task, pass the man and info pages, even web content, as a context to the AI then present it all pretty printed on the console, i.e. with markdown parsing.

    1. I just went over typed in “tar -h” because surely that is an easy one that will just print out some options. Nope. If I had used the longoption version I wouldn’t be a gaseous cloud of meat particles right now.

  7. While I think this is super cool, I think this is simply a documentation issue with Linux based distos.

    On FreeBSD the man pages already have this in the examples section. You can go directly to the example section with ‘/^Example’ in the terminal pager.

  8. The other problem with man pages is that they are all in monospaced font. Expected for a terminal but if you use a desktop browser to find eg ubuntu man pages online they are still big blocks of monospace. So 20th century, and I bet Windows doesn’t have mono spaced help files.

    The browser client mentioned above seems to present its text in a proportional font with color and monospaced example command lines – much better!

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.