rylans-node-tools
v2.0.0
Published
A collection of tiny cli tools
Readme
Rylan's Node Tools
A collection of tiny cli tools.
Installation
General
npm install -g rylans-node-tools
Take Over
- Clone repository to local machine.
- Run
yarn installto install all dependencies. - Run
yarn linkto link this package with global dependency. - Run
yarn buildoryarn devto build source code into lib folder and take over from there.
Usage
- After installation, you should be able to run
node-toolsorntas a global command. - Check
node-tools --helpto explore different useful commands.
Available Commands
greet
Basic test of the installation of the tool. Greet in specified language, or random if not provided.
| Params | Required | Value | Description | | ---------- | -------- | -------------------------- | ------------------ | | --lang, -l | N | en, fr, jp, sp, cn, it, ru | Specify a language |
For example:
$ nt greet -l en
Hi
$ nt greet
Bonjourgit
Search oh-my-zsh git command shorthands.
| Arguments | Required | Description | | --------------- | -------- | ------------------------------------------ | | <search_string> | Y | Search any git commands with search_string |
For example:
$ nt git remote
gbr: git branch remote
gr: git remote
gra: git remote add
grmv: git remote rename
grrm: git remote remove
grset: git remote set-url
grup: git remote update
grv: git remote -vcolor
Handy color converter between rgb format and Hex format.
For example:
nt color
? Input color value: 0, 111, 222
#006fdeSupported input formats:
RGB input:
rgb(255, 255, 255)
255, 255, 255
255 255 255Hex input:
#fff
#FFFFFF
fff
FFFFFFchatgpt or cg
Integrated OpenAI's ChatGPT API into command line.
For first time use, enter API_KEY generated from https://platform.openai.com/account/api-keys.
| Arguments | Required | Value | Description | | ---------- | -------- | ------ | --------------------------- | | [question] | N | String | The question to ask ChatGPT |
| Params | Required | Value | Description |
| ------------ | -------- | ------ | ---------------- |
| --config, -c | N | None | Update API_KEY |
Examples:
$ nt cg -c
Please create and/or enter your API Key from https://platform.openai.com/account/api-keys
? Enter API Key:$ nt cg how many countries are there in Asia
>>>>> Answer 💬 <<<<<<
There are 48 countries in Asia.$ nt cg
? Ask ChatGPT: What is the opposite color of cyan
>>>>> Answer 💬 <<<<<<
The opposite color of cyan is red-orange.