{"name":"dotenv-defaults","version":"5.0.2","description":"dotenv... but with defaults!","main":"src/index.js","scripts":{"test":"jest","lint":"standard"},"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":"^14.0.0"},"devDependencies":{"jest":"^27.2.0","standard":"^16.0.3"},"jest":{"coverageDirectory":"./coverage/","collectCoverage":true},"gitHead":"592f7c9a2280136979bc9d84202b8f947346319d","_id":"dotenv-defaults@5.0.2","_nodeVersion":"12.22.12","_npmVersion":"6.14.16","dist":{"integrity":"sha512-y5z4NhblzwNk8XBIYVzjLcFkANK0rxbRDO6kGOfH9QrVYIGVEX52IqwSprKVsaLHM9pnNkCSxazZF/JPydDPvA==","shasum":"065c410ea516011651e9c60dae0c8902ec53d609","tarball":"http://registry-npm.ywwl.com/dotenv-defaults/download/dotenv-defaults-5.0.2.tgz","fileCount":6,"unpackedSize":7332,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCYr3zh9PoDslO2T11RhdRddqw6Ifp2s5ho7AgRHsVUlQIhAObpo/cqW9hD+NgjfXkVtnPIHDi+kJmZ0USvbKmHiKaL"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiuSd9ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqlbBAAkujpk53giMSSnUMcj6JXHbU/c+Dh/gazT4Q4E/z9IhU29Eti\r\nLIJGWvdEo8HZ9VkfyvERLwqPAx9vBSxNF5yY8W+puE2O7T5xEY07kRq1jcJK\r\nPRujj00s5pv/kRk4oWMyQvgTgoZ40En7ZQlhiAq+XTuvzoOjTv5vc2Dr7q/A\r\n05W/fGU6uoMM6Bsr4fseDrvy8KgzLgqnM6ei+lMWhthY+QSC3ztrzdcGPaQt\r\n/1mrhVpNHCakfpt5nq6B6gELhdsQXQlS65YfkBcMEgE2WlU9RlpChupoeJA7\r\nIWiX1bsxgK92WMGfdt6wxOO7dNdkORxg9+uLQlWvpvdsPszBAN/r6W730UMQ\r\nmkHtnndg+PHHfBNl/v5bPh+4dUNWas04XTqQRZn4VF9bcrlFaEfwPt/2ioVU\r\nB7wMLDbofH/u+/tQ0zke1Dy47EVNwljxYWbjHF0UxHxuj4IB2LOXZpoVsp0E\r\nOznsZCpW27bubS0EeejWfQMn0NcQU2VS246fUudDl1UvaeYhyL0TwXGdK9+L\r\nyl5Bc9YpiI8zqp1bltbK/x76sA75eEAMDi5h1vncg5QYqOJ2wnpfaRFbClug\r\nxNI/E2cbMAfybMQgSU2rcy5KX5joVfMMWsKLpMKJQnBdyT9MqQR6vPe8YJg+\r\nLuFfP/xW0W3mb029CIXz+DNDCSmCwfbwzIk=\r\n=jXzq\r\n-----END PGP SIGNATURE-----\r\n","size":3129,"noattachment":false,"key":"/dotenv-defaults/-/dotenv-defaults-5.0.2.tgz"},"_npmUser":{"name":"mrsteele","email":"matthewsteele1@hotmail.com"},"directories":{},"maintainers":[{"name":"mrsteele","email":"matthewsteele1@hotmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/dotenv-defaults_5.0.2_1656301437792_0.38925551746681"},"_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":1656301437978,"_cnpm_publish_time":1656301437978,"dist-tags":{"latest":"6.0.0"}}