Typed Secure Config is a CLI tool for managing configuration files, with support for multiple environments and encryption. It provides a simple, interactive interface for setting and retrieving configuration values.
Install the CLI tool via npm:
npm install -g typed-secure-config
The CLI provides commands to initialize, manage, and retrieve configuration values. Below are the general options and available commands.
-V, --version Output the version number
-c, --config-dir <config-dir> Specify the path to the config file (default: "config")
-e, --env <environment> Specify the environment to use for the operation
-h, --help Display help for commands
Initialize a config dir into the project.
typed-secure-config init
Add a new environment to the configuration.
typed-secure-config add-env
Set a value in the configuration.
Example:
typed-secure-config set
Or, you can specify the key option:
typed-secure-config set -k apiKey
Get a value from the configuration.
Example:
typed-secure-config get
Or, you can specify the key option:
typed-secure-config get -k apiKey
Set an encrypted value in the configuration.
Example:
typed-secure-config set-encrypt
Or, you can specify the key option:
typed-secure-config set-encrypt -k apiKey
Get an encrypted value in the configuration.
Example:
typed-secure-config get-encrypt
Or, you can specify the key option:
typed-secure-config get-encrypt -k apiKey