Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for dotenv file #284

Merged
merged 9 commits into from Mar 31, 2019
Merged

Add support for dotenv file #284

merged 9 commits into from Mar 31, 2019

Conversation

pior
Copy link
Member

@pior pior commented Feb 17, 2019

Why

Add a limited support for dotenv file.

  • A envfile task must be declared
  • On entering the project, the .env file is read, every var defined are set in the environment
  • Thanks to the auto-unload, the variables added/changed are reverted when leaving the project

Gotchas:

  • the envfile is loaded only once, when entering the project
    • if the file is changed, the environment is not refreshed accordingly
  • if the task is removed, the variables are not unloaded (until leaving the project)

Related to #149

How

@pior pior requested a review from mlhamel as a code owner February 17, 2019 04:30
pkg/tasks/envfile.go Outdated Show resolved Hide resolved
@pior pior changed the title Add support for dotenv file WIP - Add support for dotenv file Mar 10, 2019
@pior pior changed the title WIP - Add support for dotenv file Add support for dotenv file Mar 30, 2019
@pior pior merged commit 00e9783 into master Mar 31, 2019
@pior pior deleted the envfile branch March 31, 2019 00:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants