{"name":"dotenv-defaults","version":"1.0.1","description":"dotenv... but with defaults!","main":"src/index.js","scripts":{"test":"jest","lint":"standard","travis":"npm run lint && npm t"},"repository":{"type":"git","url":"git+https://github.com/mrsteele/dotenv-defaults.git"},"keywords":["dotenv","defaults","extension","env","default","fallback"],"author":{"name":"Matt Steele","email":"matt@omnionline.us","url":"http://omnionline.us/"},"license":"MIT","bugs":{"url":"https://github.com/mrsteele/dotenv-defaults/issues"},"homepage":"https://github.com/mrsteele/dotenv-defaults#readme","dependencies":{"dotenv":"^5.0.1"},"devDependencies":{"jest":"^23.6.0","standard":"^12.0.1"},"jest":{"coverageDirectory":"./coverage/","collectCoverage":true},"gitHead":"34b448b902df21c3fd62f3b021b0cabb2adf2bf9","_id":"dotenv-defaults@1.0.1","_npmVersion":"5.6.0","_nodeVersion":"9.11.2","_npmUser":{"name":"mrsteele","email":"matt@omnionline.us"},"dist":{"integrity":"sha512-zPQOu35rF2ifWT+3cQom+n8bhtH+MoKUXfNXzV5VbiyAgABy6FP1oCkvwBajV4eBFuem7Yy2Va3z1UNx79BFLA==","shasum":"bbc5e7df992f9aff8f3d2610f484ed25af661272","tarball":"http://registry-npm.ywwl.com/dotenv-defaults/download/dotenv-defaults-1.0.1.tgz","fileCount":5,"unpackedSize":5620,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcOUYkCRA9TVsSAnZWagAAr0AP/i1Bo5TDDvWQuXzI1zUn\nTp3AcSUQUKdazrfQjuz9sZWrhQSlVcRcpYdmQ5g/OLsQdO7NwEYa1uc/T4ZZ\nUchj1AbVX03KYIqaL3KbLuuYe+CAhEtMiwWklGPw6JoGYO8xfX7OHz1Uk4Kj\nrf7rLbb5YM2RbJ2Hy0zjLGtlWLkBk6VnhXv0UD88bH3BrQ6U0+PEuvbMlRL+\nVeY1R2ER2plN0unFzN41rjHc5BFeqmVvHyBSmlgBHw7Y7GAmV29R9sFJMsmd\nRfqZlMdTQ3N2/CUfTA/iC2AjY/13DKliMhQu6nTnRaLrBRfxzLA71PMFz4wa\nikA1abWOBpCffDOFD3o71XLID6tco5UnLt2RSwzJQAv3i2gdLa9ns3llFXUs\nTyGRat17hEIpDggxbTfgM4HhpTK8E5cE1KiwHnLeRCZZ6xQIs6DlOeO7lh9g\nzSYlWIwroTszus8QF/FYf/6gB1SvnSA7rgf9wmRijwvHP75mzFenQ1GrogGb\nIUJdqkgOUJyS43VQ6Lj+Al/ade4o+qs15/hDstou2tiHraRzLk6GQhNqsx8Y\nfeh90j70JycUAkCPtu0M/4yT4IXgYMyx/n4wupu08jlUiXO5uNGUd+xGO90K\nVdMlnr/YHCMJriAgtJO0qg0e6EisHLCqasat9vy2Z5Nmh9SjFtDsJy/U/dQb\nrYBd\r\n=03iP\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFd2I/MzPnz4TXVEzIADyG3d0mRs4Qt6YuXPVb2mVxM2AiEAj7if3KzMEV/cFXbN1npg8b3WQFADe2yy3UjkBU27tPI="}],"size":2549,"noattachment":false,"key":"/dotenv-defaults/-/dotenv-defaults-1.0.1.tgz"},"maintainers":[{"name":"mrsteele","email":"matt@omnionline.us"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/dotenv-defaults_1.0.1_1547257379990_0.40376943402356535"},"_hasShrinkwrap":false,"readme":"# dotenv-defaults\n\nA dotenv system that supports defaults.\n\n### Status\n\n![npm](https://img.shields.io/npm/v/dotenv-defaults.svg)\n[![Main](https://github.com/mrsteele/dotenv-defaults/actions/workflows/main.yml/badge.svg)](https://github.com/mrsteele/dotenv-defaults/actions/workflows/main.yml)\n[![dotenv-vault](https://badge.dotenv.org/works-with.svg?r=3)](https://www.dotenv.org/get-started?r=3)\n\n### Installation\n\nUse the following to install this module:\n\n```\nnpm i dotenv-defaults --save\n```\n\n### Usage\n\nThis module supports all the features from the original [dotenv](https://www.npmjs.com/package/dotenv) module, so usage should be simple enough:\n\n```\n# .env.defaults, safe to commit\nHOST=website.com\nEMAIL=test@email.com\n```\n\n```\n# .env, DO NOT COMMIT\nHOST=mrsteele.dev\n```\n\nThe result\n\n```js\nrequire('dotenv-defaults').config()\n\n// Or you can also load it directly like this\nrequire('dotenv-defaults/config')\n\nconsole.log(process.env.HOST)\n// Outputs: mrsteele.dev\n\nconsole.log(process.env.EMAIL)\n// Outputs: test@email.com\n```\n\n##### TypeScript\nSince this module does not provide TypeScript Type Definitions if you try to import it like `import dotenv from \"dotenv-defaults\"` TypeScript will return an error.\n\nInstead you should load it like this:\n```typescript\nimport \"dotenv-defaults/config\"\n```\n\n##### CLI\nYou can also call this module directly when using the node executable.\nSo, for example if you are running a custom script with node and you want to load your environment variables you can do the following `node -r dotenv-defaults/config your-script.js`. (_When using this method, please make sure that you have installed dotenv-defaults with npm or yarn in the same directory_)\n\n### Differences\n\nThe only thing to note is that the original module supported an `options` argument in the `config` function.\n\nThis module supports that as well, but there is an added `defaults` property that can allow you to define where that file is located. An example is shown below:\n\n```js\n// all of these are the default values...\nrequire(`dotenv-defaults`).config({\n  path: './.env',\n  encoding: 'utf8',\n  defaults: './.env.defaults' // This is new\n})\n```\n\n### License\n\nMIT\n","publish_time":1547257380162,"_cnpm_publish_time":1547257380162,"dist-tags":{"latest":"6.0.0"}}