generate-env
v2.0.4
Published
With [npm](https://npmjs.org) do: ``` npm i -g generate-env ```
Downloads
16
Readme
generate-env
install
With npm do:
npm i -g generate-env
How to use
At the env.config.json file level type generatenv + branch name + file name
Branches accepted prod, dev, qa
Example
generatenv dev env.config.json
File Config
The file name can be anything as long as it is in json format
If you do not set a file in the command, it will be used env.config.json
File Format
Use V1 :
{
"version":1,
"file":".env",
"airtableToken":"Airtable Key",
"airtableUrl":"Airtable Api url",
"airtableBaseDev":"Airtable base DEV",
"airtableBaseProd":"Airtable base Prod",
"airtableBaseQa":"Airtable base QA",
"tableEnvs":"Name of the table where you save the env",
"env":[
{
"identifier":"Identifier of your variable",
"varName":"Variable name"},
]
}
Use V2 :
{
"version":1,
"file":".env",
"airtableToken":"Airtable Key",
"airtableUrl":"Airtable Api url",
"airtableBaseDev":"Airtable base DEV",
"airtableBaseProd":"Airtable base Prod",
"airtableBaseQa":"Airtable base QA",
"tableEnvs":"Name of the table where you save the env",
"tableApplications":"Name of the table where you save your applications",
"applicationName":"Name of the application to create the env",
"env":[]
}
To add prefix:
{
"prefix": true,
"namePrefix":"MY_PREFIX",
}
Update:
V: 2.0.0 Add new functionalities and configuration formats
license
MIT