||6 months ago|
|.vscode||6 months ago|
|src||6 months ago|
|.drone.yml||6 months ago|
|.gitignore||6 months ago|
|.npmrc||6 months ago|
|.nvmrc||6 months ago|
|.prettierignore||6 months ago|
|.prettierrc||6 months ago|
|Makefile||6 months ago|
|README.md||6 months ago|
|package.json||6 months ago|
|pnpm-lock.yaml||6 months ago|
|tsconfig.json||6 months ago|
LT-Commander is a "helper" library for building CLI applications with Commander.
LT-Commander exports two configuration utilities, each of which provide a unique set of features/functionality.
This class makes use of the configstore dependency. It provides a number of methods for getting, updating, deleting, etc., of configuration settings.
Easily load and persist config without having to think about where and how.
The config is stored in a JSON file located in
This class makes use of the cosmiconfig dependency which only provides a single method for loading the config file content (if it exists):
Cosmiconfig searches for and loads configuration for your program.
By default, Cosmiconfig will start where you tell it to start and search up the directory tree for the following:
- A package.json property
- A JSON or YAML, extensionless "rc file"
- An "rc file" with the extensions
For example, if your module's name is "myapp", cosmiconfig will search up the directory tree for configuration in the following places:
myappproperty in package.json
.myapprcfile in JSON or YAML format
myapp.config.cjsCommonJS module exporting an object
Cosmiconfig continues to search up the directory tree, checking each of these places in each directory, until it finds some acceptable configuration (or hits the home directory). If a path is provided to the
load function, then the search begins there.