Giter Site home page Giter Site logo

env's People

Contributors

dshaw avatar

Stargazers

 avatar Gerard jourdain Grégoire Charles  avatar Roman avatar Paolo avatar Erik Nomitch avatar Chris avatar  avatar José Cage  avatar M Haidar Hanif avatar Robert Bailey avatar Ryan Martin avatar Kier Borromeo avatar jon ⚝ avatar Bryan "BJ" Hoffpauir avatar Joseph Werle avatar Aswini S avatar Francois-Guillaume Ribreau avatar Michael Duane Mooring avatar node-migrator-bot avatar Jonathan avatar Jason Cline avatar Sérgio Ramos avatar Nick Cairns avatar Franz Enzenhofer avatar Clint Andrew Hall avatar Joe McCann avatar Vitalii avatar  avatar

Watchers

 avatar Nelson avatar James Cloos avatar  avatar  avatar

env's Issues

CLI for validation / install

Would be cool to have a CLI for:

  • validating an environment before starting the process.
  • listing currently set values for required and specified env vars
  • setting or modifying env vars.

Extend Functionality to Export the vars loaded from env.json into process.env Object ?

Hi @dshaw,
We would really like to extend _env_ to make all configuration loaded from env.json available as process.env.VAR_NAME would you accept a PR for this extension.
This would simply be a loop to itterate over the entries in env.json and add them to the process.env object using your env.set method.

(100% backward compatibility will be maintained and 100% test coverage)
Let us know.
Thanks!

Enumerate appropriate values? Validation rules?

I'm assuming the "1" values in the JSON file are just "truthy" values for now. What would you think of enumerating possible values? Perhaps even validation rules, (though that may be pushing it). For instance:

{
  'ENVIRONMENT' : {
    'values' : [ 'dev', 'prod', 'test' ]
  },
  'PORT' : {
    'validate' : function(value) {
      return value < 9999 && val > 1000;
    }
}

I don't think this validating impl "feels" right; it probably belongs in the biz logic, but there's something to be said for having it in the env spec for clarity. You get the idea. Thoughts?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.