heroku-set-env

1.0.1 • Public • Published



heroku-set-env


npm package downloads license

Set all config vars from .env in Heroku project using one-command CLI.

Installation

npm i -g heroku-set-env
#or
yarn global add heroku-set-env

Usage

You need to login Heroku CLI first. Run heroku login if you are not logged in.

    $ heroku-set-env --help

    Usage
        $ heroku-set-env -a "your-app-name"

    Options
        --app -a App name of heroku project (required)
        --path -p  Path of .env file (optional)
        --help

    Example
        $ heroku-set-env -a example-project
        $ heroku-set-env -a example-project -p .env.example

Example

npm i --save-dev heroku-set-env

then set script in package.json

{
    ...
    "scripts":{
        ...
        "heroku-config": "heroku-set-env -a your-app-name -p .env.heroku"
    }
}

then run script

npm run heroku-config

then all vars in .env.heroku set to the your Heroku project.

Package Sidebar

Install

npm i heroku-set-env

Weekly Downloads

0

Version

1.0.1

License

MIT

Unpacked Size

5.5 kB

Total Files

6

Last publish

Collaborators

  • metehankurucu