• Stars
    star
    11
  • Rank 1,694,829 (Top 34 %)
  • Language
    Crystal
  • License
    MIT License
  • Created about 9 years ago
  • Updated over 8 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

App configuration for crystal applications.

ambience Build Status

App configuration using ENV for Crystal applications inspired by figaro.

Installation

Add this to your application's shard.yml:

dependencies:
  ambience:
    github: vjdhama/ambience
    version: 0.4.2

Usage

require "ambience"

Ambience.application("configuration_file_path", "environment")
Ambience.load

Refer example kemal application for more insight.

Example configuration file

api_url: example.com
development:
  app_id: foobar123
  app_key: barfoo123

production:
  app_id: bar123foo
  app_key: 123foobar

##TODO'S

  • Convenience Proxy Methods.
  • Required keys convenience method.
  • Cli for Ambience.
  • Add examples for frost.
  • Add examples for kemal.

Contributing

  1. Fork it ( https://github.com/vjdhama/ambience/fork )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request

Contributors

  • vjdhama - Vijay Dhama : creator, maintainer