Skip to content

liamzh/tldr-node-client

 
 

Repository files navigation

Travis CI Dependency Status devDependency Status

tldr-node-client

A Node.js based command-line client for tldr.

tldr screenshot

Installing

NPM

$ npm install -g tldr

Note: TLDR is still in early versions. We try to minimise breaking changes, but if you run into issues please try to download the latest package again.

Usage

To see tldr pages:

  • tldr <command> show examples for this command
  • tldr --list show all available pages
  • tldr --random show a page at random
  • tldr --random-example show a single random example

The client caches a copy of all pages locally, in ~/.tldr. There are more commands to control the local cache:

  • tldr --update download the latest pages
  • tldr --clear-cache delete the entire local cache

As a contributor, you might also need the following commands:

  • tldr --render <path> render a local page for testing purposes

Configuration

You can configure the tldr client by adding a .tldrrc file in your HOME directory. This file has to be valid JSON:

{
  "colors": {
    "text": "green",
    "command-background": "black",
    "command-foreground": "red",
    "command-token": "white"
  }
}

As a contributor, you can also point to your own fork or branch:

{
  "repository" : "myfork/tldr",
  // or
  "repository" : "myfork/tldr#mybranch",  
}

Contributing

Contribution are most welcome! Have a look over here for a few rough guidelines.

About

Node.js command line client for tldr

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%