{"name":"dotenv-defaults","version":"5.0.1","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":"83ec54a315619bea7bdc7903f204153f8d5e8566","_id":"dotenv-defaults@5.0.1","_nodeVersion":"12.22.12","_npmVersion":"6.14.16","dist":{"integrity":"sha512-ijs6pWd35krTEbJ/+wfJv7YIyHzSqZ8Ld7TxPEuxOqYBjQr5qZjkZ7qOflfFfm7/IdONL5CMyvBT5dwGv/WHsA==","shasum":"7f4c8a866994ee450b8d55c77f4df42c15ceafe7","tarball":"http://registry-npm.ywwl.com/dotenv-defaults/download/dotenv-defaults-5.0.1.tgz","fileCount":6,"unpackedSize":7348,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICatq4rcTkE4wig8oxQ6TkbmwxFYdv3ODZ1M1h91QdJjAiABZV5+wOBppWw1EUewfsetfZrHlzBCkCpplAWUAI5fKQ=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiuSakACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqPJxAAogcEPc8hl+to+tsxGDmxJidsFw3I6ZWxfdnb7uKyEek2m4vu\r\nR17YBPDAznQACjRBpw1GfUvD+eTIpXa2xDTyeWwfJTVHTXIRlX/WOSLBzeOm\r\n3t99MkefWZhYV4YlZPnIxS+iyyIoTvQRQpft1fOxOZ/fY7ifvSN75IHANih0\r\nxgWFd6kgXwfLpRyo6oa1c1DvAbRWQKtqEjHO/7NtVoaXmispZKzGSQOdW7ml\r\nwFCMWGNyUHH92ygQVdnsmVVmPHrh+p/LXniDTWLCYAI5Jb8eaS8d1v0QQDZZ\r\n9MKi+3eDWII/g7jekIoEdaIO2w7wemgVEpOHHuc0iq9nFFerixgHeYE7uhCn\r\nZxgRDq+W87y6rHGIPu9yJmu9kILMDciUJ2+WwG8WirkyEOQ9CzQK3v2sEBiE\r\njN/xc1hx8w1tUqc7aC9sU/91cXN6YHS9qo1bDU2rYc8P7DCRC/eWbuN+MmNP\r\nsOzVZcfTcgc5eEFYVntSwTB1MCaOeW92BFokr8ir49z/dV3f/iOXQFSk0pVT\r\nyhMreKy2bSPNkZTMVLHPS3SLJHYFV/R4dz72yyiTf6eArDDHzgMxKPN+9IVX\r\nVUk6PYQBw81Dp1FIwlwY7mKbHCOLmIt/0HUrjOHivv2Acsk6TOgfF7CMvcfW\r\ndQomlBVT3svSUIDuobMLjdWjlayOA2bj4kQ=\r\n=L45j\r\n-----END PGP SIGNATURE-----\r\n","size":3127,"noattachment":false,"key":"/dotenv-defaults/-/dotenv-defaults-5.0.1.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.1_1656301219878_0.8745630036301095"},"_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":1656301220048,"_cnpm_publish_time":1656301220048,"dist-tags":{"latest":"6.0.0"}}