|
| 1 | +## kelp-config |
| 2 | + |
| 3 | +:sparkles: Simple light-weight configuration for kelp |
| 4 | + |
| 5 | + |
| 6 | +[](https://travis-ci.org/song940/kelp-config) |
| 7 | + |
| 8 | +### Installation |
| 9 | +```` |
| 10 | +$ npm install kelp-config --save |
| 11 | +```` |
| 12 | + |
| 13 | +### Example |
| 14 | + |
| 15 | +config/default.js |
| 16 | + |
| 17 | +```js |
| 18 | +module.exports = { |
| 19 | + name: 'default' |
| 20 | +}; |
| 21 | +``` |
| 22 | + |
| 23 | +config/test.js |
| 24 | + |
| 25 | +```js |
| 26 | +module.exports = { |
| 27 | + name: 'test' |
| 28 | +}; |
| 29 | +``` |
| 30 | + |
| 31 | +config/production.js |
| 32 | + |
| 33 | +```js |
| 34 | +module.exports = { |
| 35 | + name: 'production' |
| 36 | +}; |
| 37 | +``` |
| 38 | + |
| 39 | + |
| 40 | +````bash |
| 41 | +~$ node |
| 42 | +> require('kelp-config').name //-> default |
| 43 | +```` |
| 44 | + |
| 45 | +````bash |
| 46 | +~$ NODE_ENV=production node |
| 47 | +> require('kelp-config').name //-> production |
| 48 | +```` |
| 49 | + |
| 50 | +### Contributing |
| 51 | +- Fork this repo |
| 52 | +- Clone your repo |
| 53 | +- Install dependencies |
| 54 | +- Checkout a feature branch |
| 55 | +- Feel free to add your features |
| 56 | +- Make sure your features are fully tested |
| 57 | +- Open a pull request, and enjoy <3 |
| 58 | + |
| 59 | +### MIT license |
| 60 | +Copyright (c) 2016 lsong |
| 61 | + |
| 62 | +Permission is hereby granted, free of charge, to any person obtaining a copy |
| 63 | +of this software and associated documentation files (the "Software"), to deal |
| 64 | +in the Software without restriction, including without limitation the rights |
| 65 | +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell |
| 66 | +copies of the Software, and to permit persons to whom the Software is |
| 67 | +furnished to do so, subject to the following conditions: |
| 68 | + |
| 69 | +The above copyright notice and this permission notice shall be included in |
| 70 | +all copies or substantial portions of the Software. |
| 71 | + |
| 72 | +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR |
| 73 | +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, |
| 74 | +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE |
| 75 | +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER |
| 76 | +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, |
| 77 | +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN |
| 78 | +THE SOFTWARE. |
| 79 | + |
| 80 | +--- |
0 commit comments