Contactually's environmental variable management CLI. It updates your local .env as well as runs the commands for your staging and production values.

Installation

yarn add --dev env-manager-cli

Implementation

envManager.js

import envManager from ' env-manager-cli ' envManager ( { stagingCommand : ( key , value ) => ` heroku config:set ${ key } = ${ value } test ` , productionCommand : ( key , value ) => ` heroku config:set ${ key } = ${ value } prod ` } )

package.json

" scripts " : { " env:set " : " node ./envManager " , } ,

now running yarn env:set will result in the following prompt

Configuration