{"name":"env-paths","version":"3.0.0","description":"Get paths for storing things like data, config, cache, etc","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/env-paths.git"},"funding":"https://github.com/sponsors/sindresorhus","author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"https://sindresorhus.com"},"type":"module","exports":"./index.js","engines":{"node":"^12.20.0 || ^14.13.1 || >=16.0.0"},"scripts":{"test":"xo && ava && tsd"},"keywords":["common","user","paths","env","environment","directory","dir","appdir","path","data","config","cache","logs","temp","linux","unix"],"devDependencies":{"ava":"^3.15.0","tsd":"^0.17.0","xo":"^0.44.0"},"gitHead":"f1729272888f45f6584e74dc4d0af3aecba9e7e8","bugs":{"url":"https://github.com/sindresorhus/env-paths/issues"},"homepage":"https://github.com/sindresorhus/env-paths#readme","_id":"env-paths@3.0.0","_nodeVersion":"14.17.5","_npmVersion":"7.20.3","dist":{"integrity":"sha512-dtJUTepzMW3Lm/NPxRf3wP4642UWhjL2sQxc+ym2YMj1m/H2zDNQOlezafzkHwn6sMstjHTwG6iQQsctDW/b1A==","shasum":"2f1e89c2f6dbd3408e1b1711dd82d62e317f58da","tarball":"http://registry-npm.ywwl.com/env-paths/download/env-paths-3.0.0.tgz","fileCount":5,"unpackedSize":9815,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhKUgKCRA9TVsSAnZWagAAgqgQAIk5pYJ68JuAFv0mbV4b\n/oNXv4IBA2eEXAqDk4vno9RdwAUEMyD07JThmn/J5jR7FKPImZj6Qh31RRXk\nPdVI8Hgvtt+kdXp/nDhEGjKQlB3xNIyP/QaYSoTd3ZcIITYewvOko0+bZSzo\nX3csXgvBrY4TK5d+NaOIT58zM7DYgIspuC93S/BZCAaPIJhjz+VxwxTYrNET\nvwzzS1ViN72eOIBasxUo0FI6uCg1JnSY1AEJIhkAr1d0Ro/FtdmeqcVcG1Ze\noUUAP4CXFpiptCGhHwpVZg05bOH/pqeNNxbekTtVRmgxUNKm9zmA2S+LfGtu\njGkS9vRLcFNhKSUly5LLDno5K6vQRMZVBVJJ7184VbXohPElGy4kFjf10SZV\nb5+SORQR1j4FHmsllUNURGA/H9eUbzpdaGV9bX+572xTvP53EB6WxVpciLvB\nzexeVL8p6Dcf8XSK6EVfBP18/GgEOQYMYUsd3L6W7XzZFeLTk1cEQ7A0V0SY\nLfdZTOx2uC1WKwaen9ZtJJ4cDojkfkWM9OPwEEGarh3bqmvCgOPRAxADmX1p\nNuqUsPGBlyY6TOeJWBS4NM7SdVNIAIvg7yO68rIDseFbL4n+HFwhJr4eAsjU\nSQMVNPA1EwPd72VvFTx0qUEsEHHnM0cc+Rt9MWOWLqoC6FhWCPz/GS4h5Fyf\nGM4V\r\n=2ZH6\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIChqNuhVAeCfpjgoM9BXlxu8lvgnweJgd66MlUdMvp9oAiEAx4bbJStW8xnzj7R1JnNlu+VpEaHdDPL9UumA29JKcDk="}],"size":3254,"noattachment":false,"key":"/env-paths/-/env-paths-3.0.0.tgz"},"_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"directories":{},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/env-paths_3.0.0_1630095370252_0.24084207963657178"},"_hasShrinkwrap":false,"readme":"# env-paths\n\n> Get paths for storing things like data, config, cache, etc\n\nUses the correct OS-specific paths. Most developers get this wrong.\n\n## Install\n\n```\n$ npm install env-paths\n```\n\n## Usage\n\n```js\nimport envPaths from 'env-paths';\n\nconst paths = envPaths('MyApp');\n\npaths.data;\n//=> '/home/sindresorhus/.local/share/MyApp-nodejs'\n\npaths.config\n//=> '/home/sindresorhus/.config/MyApp-nodejs'\n```\n\n## API\n\n### paths = envPaths(name, options?)\n\nNote: It only generates the path strings. It doesn't create the directories for you. You could use [`make-dir`](https://github.com/sindresorhus/make-dir) to create the directories.\n\n#### name\n\nType: `string`\n\nThe name of your project. Used to generate the paths.\n\n#### options\n\nType: `object`\n\n##### suffix\n\nType: `string`\\\nDefault: `'nodejs'`\n\n**Don't use this option unless you really have to!**\n\nSuffix appended to the project name to avoid name conflicts with native\napps. Pass an empty string to disable it.\n\n### paths.data\n\nDirectory for data files.\n\nExample locations (with the default `nodejs` [suffix](#suffix)):\n\n- macOS: `~/Library/Application Support/MyApp-nodejs`\n- Windows: `%LOCALAPPDATA%\\MyApp-nodejs\\Data` (for example, `C:\\Users\\USERNAME\\AppData\\Local\\MyApp-nodejs\\Data`)\n- Linux: `~/.local/share/MyApp-nodejs` (or `$XDG_DATA_HOME/MyApp-nodejs`)\n\n### paths.config\n\nDirectory for config files.\n\nExample locations (with the default `nodejs` [suffix](#suffix)):\n\n- macOS: `~/Library/Preferences/MyApp-nodejs`\n- Windows: `%APPDATA%\\MyApp-nodejs\\Config` (for example, `C:\\Users\\USERNAME\\AppData\\Roaming\\MyApp-nodejs\\Config`)\n- Linux: `~/.config/MyApp-nodejs` (or `$XDG_CONFIG_HOME/MyApp-nodejs`)\n\n### paths.cache\n\nDirectory for non-essential data files.\n\nExample locations (with the default `nodejs` [suffix](#suffix)):\n\n- macOS: `~/Library/Caches/MyApp-nodejs`\n- Windows: `%LOCALAPPDATA%\\MyApp-nodejs\\Cache` (for example, `C:\\Users\\USERNAME\\AppData\\Local\\MyApp-nodejs\\Cache`)\n- Linux: `~/.cache/MyApp-nodejs` (or `$XDG_CACHE_HOME/MyApp-nodejs`)\n\n### paths.log\n\nDirectory for log files.\n\nExample locations (with the default `nodejs` [suffix](#suffix)):\n\n- macOS: `~/Library/Logs/MyApp-nodejs`\n- Windows: `%LOCALAPPDATA%\\MyApp-nodejs\\Log` (for example, `C:\\Users\\USERNAME\\AppData\\Local\\MyApp-nodejs\\Log`)\n- Linux: `~/.local/state/MyApp-nodejs` (or `$XDG_STATE_HOME/MyApp-nodejs`)\n\n### paths.temp\n\nDirectory for temporary files.\n\nExample locations (with the default `nodejs` [suffix](#suffix)):\n\n- macOS: `/var/folders/jf/f2twvvvs5jl_m49tf034ffpw0000gn/T/MyApp-nodejs`\n- Windows: `%LOCALAPPDATA%\\Temp\\MyApp-nodejs` (for example, `C:\\Users\\USERNAME\\AppData\\Local\\Temp\\MyApp-nodejs`)\n- Linux: `/tmp/USERNAME/MyApp-nodejs`\n\n---\n\n<div align=\"center\">\n\t<b>\n\t\t<a href=\"https://tidelift.com/subscription/pkg/npm-env-paths?utm_source=npm-env-paths&utm_medium=referral&utm_campaign=readme\">Get professional support for this package with a Tidelift subscription</a>\n\t</b>\n\t<br>\n\t<sub>\n\t\tTidelift helps make open source sustainable for maintainers while giving companies<br>assurances about security, maintenance, and licensing for their dependencies.\n\t</sub>\n</div>\n","publish_time":1630095370424,"_cnpm_publish_time":1630095370424,"dist-tags":{"latest":"4.0.0"}}