Miss any of our Open RFC calls?Watch the recordings here! »

terminal-quotes

1.0.5 • Public • Published

🌟 Terminal Quotes 🌟

Fresh custom quotes in your terminal

Install

$ npm install -g terminal-quotes

Usage

$ terminal-quotes [OPTIONS]
or
$ node <path/to/terminal-quotes/cli.js> [OPTIONS]

Example

Output a random quote from programming-quotes-json

$ terminal-quotes

🌟 Terminal Quotes 🌟

"Software is like sex: it's better when it's free."

--Linus Torvalds

$

Options

  --total, -t  Total quotes to print, defaults 1

$ quotes is an alias of $ terminal-quotes

Show some quotes when open your terminal

  • Edit your bashrc file
    $ nano ~/.bashrc
  • At the end of the file add:
    terminal-quotes
    or
    node <path/to/terminal-quotes/cli.js>

Use with custom quotes

Just update in the package.json the config property like this:

...
"config"{
  "source": "http://url.com/myAwesomeQuotes/array.json",
  "quoteTextProp": "quote",
  "authorTextProp": "author"
},
...

where array.json looks like

[
  {
    "quote": "Life is awesome!",
    "author": "unknow",
    "source": "https://twitter.com/juliomatcom"
  },
  ...
]

terminal-quotes will fetch the .json of quotes and for every quotes print quoteTextProp value as the quote itself and authorTextProp value as the author.

Note: terminal-quotes not support redirection, make sure the source URL returns a response 2xx and not a redirect.

License

MIT © Julio Cesar Martin

Install

npm i terminal-quotes

DownloadsWeekly Downloads

1

Version

1.0.5

License

ISC

Last publish

Collaborators

  • avatar