{ "info": { "author": "shadow-light", "author_email": "42055707+shadow-light@users.noreply.github.com", "bugtrack_url": null, "classifiers": [], "description": "# npmenv\n\nA wrapper for npm that stores node_modules outside of project and provides easy access to them.\n\n`npmenv` is a Python module inspired by `pipenv` in that it stores packages outside of projects (in an OS-specific dir) to avoid cluttering projects. It also has a `run` command that puts `node_modules/.bin` in `PATH` before running the given command. If you `install node` in a project then it will have the added benefit of using that node version to run your code and third-party scripts. You can then lock down your node version per-project and upgrade them individually when desired.\n\n__Install:__ `pip install npmenv`\\\n__Supports:__ All platforms (Linux, MacOS, Windows)\\\n__Requires:__ Python 3.6+\n\n[PyPI package](https://pypi.org/project/npmenv/) | [Source](https://github.com/shadow-light/npmenv)\n\n\n## How it works\n\nAside from `env-...` commands, npmenv hands over to `npm`. But before handing over, it symlinks your `package.json` and/or `package-lock.json` into the virtual environment and runs npm in that environment. You can access any `node_modules` files via the path returned by `npmenv env-location`, which will stay the same even if the environment is removed and recreated (though not if your project path changes).\n\n__Note:__ npmenv does not handle any other files generated by npm (such as shrinkwrap), though more features may be added in future.\n\n\n## CLI usage\n```\nnpmenv 0.2.0\n\nenv-list List all currently existing environments\nenv-location Output path to env for current dir (may not exist yet)\nenv-modules [name] List items in node_modules (recursive if package name given)\nenv-run cmd [args] Run command with env's bin dir in start of PATH\nenv-rm [env_id] Remove the env for current dir (or env with given id)\nenv-cleanup Remove envs for projects that no longer exist\n*any npm command*\n```\n\n## Module API\n```\nclass NpmenvException(builtins.Exception)\n Exception for npmenv-related issues\n\nenv_cleanup() -> List[Tuple[str, pathlib.Path, str]]\n Remove envs for projects that no longer exist (no package or lock file)\n\nenv_list() -> List[Tuple[str, pathlib.Path, Union[str, NoneType]]]\n Return list of tuples (env id, project dir, issue with project existance)\n\nenv_location(proj_dir:Union[pathlib.Path, str]=None) -> pathlib.Path\n Return env dir path for given project dir (may/may not exist yet)\n\nenv_npm(args:str='', proj_dir:Union[pathlib.Path, str]=None) -> subprocess.CompletedProcess\n Execute npm with given args in env dir of given project dir\n\nenv_rm(identifier:Union[pathlib.Path, str]=None) -> pathlib.Path\n Remove the env for given project dir or env id (defaults to CWD)\n\nenv_run(args:str, proj_dir:Union[pathlib.Path, str]=None, run_kwargs:Any={}) -> subprocess.CompletedProcess\n Run a command with node_modules/.bin at start of PATH environment variable\n\n```\n\n## Version history\n```\n0.2.0 Added run_kwargs arg to env_run\n0.1.2 Added env-modules command\n0.0.2 Improved typing support (no functional changes)\n0.0.1 Improved documentation (no functional changes)\n0.0.0 Version 0.0.0\n```\n\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/shadow-light/npmenv", "keywords": "", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "npmenv", "package_url": "https://pypi.org/project/npmenv/", "platform": "", "project_url": "https://pypi.org/project/npmenv/", "project_urls": { "Homepage": "https://github.com/shadow-light/npmenv" }, "release_url": "https://pypi.org/project/npmenv/0.2.0/", "requires_dist": [ "appdirs (==1.*,>=1.4.3)" ], "requires_python": "~=3.6", "summary": "A wrapper for npm that stores node_modules outside of project and provides easy access to them.", "version": "0.2.0" }, "last_serial": 4362796, "releases": { "0.0.0": [ { "comment_text": "", "digests": { "md5": "9b99153ce72e66777e220771d83cc2bf", "sha256": "dd3fe45b6572e95a0510feec08cd298ef506227c73c237b3e11f80c85441ac07" }, "downloads": -1, "filename": "npmenv-0.0.0-py3-none-any.whl", "has_sig": true, "md5_digest": "9b99153ce72e66777e220771d83cc2bf", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": "~=3.6", "size": 5544, "upload_time": "2018-09-04T06:36:43", "url": "https://files.pythonhosted.org/packages/c2/44/db5eb11ab78d5d8a38b4e7e2a2b5555f861d3ac136c443928e279b99447a/npmenv-0.0.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "7073533e80612643809e1dec46a6b9bb", "sha256": "eed36ee639faece1dfb747ffd8b815a027f2fddd3e5a67aa94ec1f748a7097ab" }, "downloads": -1, "filename": "npmenv-0.0.0.tar.gz", "has_sig": true, "md5_digest": "7073533e80612643809e1dec46a6b9bb", "packagetype": "sdist", "python_version": "source", "requires_python": "~=3.6", "size": 5089, "upload_time": "2018-09-04T06:36:44", "url": "https://files.pythonhosted.org/packages/4e/56/5c89630f163ac26c08207454d41655bd8fc668cad05d04cf51df78b0f3d0/npmenv-0.0.0.tar.gz" } ], "0.0.1": [ { "comment_text": "", "digests": { "md5": "9f1e76dc9bce2b21b53e612e2ef3420e", "sha256": "c112a32030e58c56e672bf833ad003d2cc75479dc64d8fd498d2a9454308b69d" }, "downloads": -1, "filename": "npmenv-0.0.1-py3-none-any.whl", "has_sig": true, "md5_digest": "9f1e76dc9bce2b21b53e612e2ef3420e", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": "~=3.6", "size": 5876, "upload_time": "2018-09-04T11:42:11", "url": "https://files.pythonhosted.org/packages/2e/61/8825f6ff6cf5ac2efc68cd8e51099ab59aedf997e49beabceb1ea3ad5722/npmenv-0.0.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "2385ec6cd4019b98e781448bbfbee6fe", "sha256": "ff650c2a6c477e25087bae78e884486da7e51f1efe7cd11dc75b81f245e054f5" }, "downloads": -1, "filename": "npmenv-0.0.1.tar.gz", "has_sig": true, "md5_digest": "2385ec6cd4019b98e781448bbfbee6fe", "packagetype": "sdist", "python_version": "source", "requires_python": "~=3.6", "size": 5480, "upload_time": "2018-09-04T11:42:13", "url": "https://files.pythonhosted.org/packages/c9/83/35aba01ac37491819f083d530b24fabe5f53b22b9dcef90ab6aed20b4052/npmenv-0.0.1.tar.gz" } ], "0.0.2": [ { "comment_text": "", "digests": { "md5": "fe5f20366440670fe34e8ab3fbe79a6f", "sha256": "b04102d88eb268265f624a3ea181da63dcf78c3eb4ea889fcb85b18890a76135" }, "downloads": -1, "filename": "npmenv-0.0.2-py3-none-any.whl", "has_sig": true, "md5_digest": "fe5f20366440670fe34e8ab3fbe79a6f", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": "~=3.6", "size": 5906, "upload_time": "2018-09-09T12:44:56", "url": "https://files.pythonhosted.org/packages/46/bb/7eba1e14fec88b85b5a9834e3f60f8bdd6dd14dd5935e03fc399465294a2/npmenv-0.0.2-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "83e5efb6b8227f0ab1d4c129f07a042e", "sha256": "7bebacbcf9228b1778d01aa3ef17ba52a943753a58de02312b425735faf8c600" }, "downloads": -1, "filename": "npmenv-0.0.2.tar.gz", "has_sig": true, "md5_digest": "83e5efb6b8227f0ab1d4c129f07a042e", "packagetype": "sdist", "python_version": "source", "requires_python": "~=3.6", "size": 5549, "upload_time": "2018-09-09T12:44:58", "url": "https://files.pythonhosted.org/packages/c0/95/333a4961174b90b7cb93cd88b691e7d5c5e7bd4607e7bb3819e91fc3a5c3/npmenv-0.0.2.tar.gz" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "316bbe690536dcf5fa0b8d0e3f5515ac", "sha256": "f9349ab269a07085f4b12550296d849e3f466f4633b10246c3a80b049d3bac88" }, "downloads": -1, "filename": "npmenv-0.1.2-py3-none-any.whl", "has_sig": true, "md5_digest": "316bbe690536dcf5fa0b8d0e3f5515ac", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": "~=3.6", "size": 6299, "upload_time": "2018-09-10T10:51:03", "url": "https://files.pythonhosted.org/packages/8a/32/353fec7be0146528343a5763727ed449b1125d741140827f7a5fd956f6fe/npmenv-0.1.2-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "101166f9ec33abadfd1da2cacdef0adc", "sha256": "7460cbd84f07fd9b155ff1340a497b4e442aa085473b957b18c4a2a62ca38574" }, "downloads": -1, "filename": "npmenv-0.1.2.tar.gz", "has_sig": true, "md5_digest": "101166f9ec33abadfd1da2cacdef0adc", "packagetype": "sdist", "python_version": "source", "requires_python": "~=3.6", "size": 5899, "upload_time": "2018-09-10T10:51:05", "url": "https://files.pythonhosted.org/packages/4c/5d/4e786a1246cfbcb70e3f544cb8fb5dd880c77fe776548a9d3c6ea453b573/npmenv-0.1.2.tar.gz" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "f437aa42c4851a8fff5e55a9b348cbd0", "sha256": "83392ce10d0eb8d34e49aa76149db810784a042891f875b5a0b58e145de9bcf7" }, "downloads": -1, "filename": "npmenv-0.2.0-py3-none-any.whl", "has_sig": true, "md5_digest": "f437aa42c4851a8fff5e55a9b348cbd0", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": "~=3.6", "size": 6345, "upload_time": "2018-10-11T04:40:56", "url": "https://files.pythonhosted.org/packages/b9/e3/e2a6350f988773728ceab8797940a312e14dc69c4cad9921fe61d4cd1d71/npmenv-0.2.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "633932319e3be15da26d913673c3a2ee", "sha256": "2276ae773943131beea626669bb5fe32d4a7dda280ff5a0adb1d97d80cfccb4e" }, "downloads": -1, "filename": "npmenv-0.2.0.tar.gz", "has_sig": true, "md5_digest": "633932319e3be15da26d913673c3a2ee", "packagetype": "sdist", "python_version": "source", "requires_python": "~=3.6", "size": 5941, "upload_time": "2018-10-11T04:40:58", "url": "https://files.pythonhosted.org/packages/f0/c8/3168bbad4fc3d567cbe530adafa82c3afcd637721543c1c7726ab19a8a0b/npmenv-0.2.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "f437aa42c4851a8fff5e55a9b348cbd0", "sha256": "83392ce10d0eb8d34e49aa76149db810784a042891f875b5a0b58e145de9bcf7" }, "downloads": -1, "filename": "npmenv-0.2.0-py3-none-any.whl", "has_sig": true, "md5_digest": "f437aa42c4851a8fff5e55a9b348cbd0", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": "~=3.6", "size": 6345, "upload_time": "2018-10-11T04:40:56", "url": "https://files.pythonhosted.org/packages/b9/e3/e2a6350f988773728ceab8797940a312e14dc69c4cad9921fe61d4cd1d71/npmenv-0.2.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "633932319e3be15da26d913673c3a2ee", "sha256": "2276ae773943131beea626669bb5fe32d4a7dda280ff5a0adb1d97d80cfccb4e" }, "downloads": -1, "filename": "npmenv-0.2.0.tar.gz", "has_sig": true, "md5_digest": "633932319e3be15da26d913673c3a2ee", "packagetype": "sdist", "python_version": "source", "requires_python": "~=3.6", "size": 5941, "upload_time": "2018-10-11T04:40:58", "url": "https://files.pythonhosted.org/packages/f0/c8/3168bbad4fc3d567cbe530adafa82c3afcd637721543c1c7726ab19a8a0b/npmenv-0.2.0.tar.gz" } ] }