https://github.com/shiro-saber/node-env-installer
Plugin for Oh my zsh (https://github.com/ohmyzsh/ohmyzsh) that controls the versions of NodeJS projects with NVM.
https://github.com/shiro-saber/node-env-installer
nvm oh-my-zsh oh-my-zsh-plugin
Last synced: about 18 hours ago
JSON representation
Plugin for Oh my zsh (https://github.com/ohmyzsh/ohmyzsh) that controls the versions of NodeJS projects with NVM.
- Host: GitHub
- URL: https://github.com/shiro-saber/node-env-installer
- Owner: shiro-saber
- License: gpl-3.0
- Created: 2020-01-10T04:10:03.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2020-03-25T00:31:23.000Z (over 5 years ago)
- Last Synced: 2024-04-15T13:23:30.424Z (over 1 year ago)
- Topics: nvm, oh-my-zsh, oh-my-zsh-plugin
- Language: Shell
- Homepage:
- Size: 66.4 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
- awesome-zsh-plugins - node-env-installer - Uses `nvm` to install new versions and modules for the current project. (Plugins / ZSH on Windows)
- fucking-awesome-zsh-plugins - node-env-installer - Uses `nvm` to install new versions and modules for the current project. (Plugins / ZSH on Windows)
- awesome-zsh-plugins - node-env-installer - Uses `nvm` to install new versions and modules for the current project. (Plugins / Zinit (née zplugin))
README
# Node Env Installer
This plugin lets nvm install new versions and modules for the current project.
Here is a preview of the plugin

## Functionality
The plugin is looking for a package.json file to get a NodeJS version and then set it as the current using version.
After getting a node version, if the version is not currently installed in the machine this plugin will install it for you.
You also can configure the implicit installation/update of your package by environment variables, this will use the [npm-install-changed](https://www.npmjs.com/package/npm-install-changed) for the update of the modules.
## Plugin Requirements
For the use of this plugin it's required the installation of:
* [nvm](https://github.com/nvm-sh/nvm)
* [zsh](https://github.com/ohmyzsh/ohmyzsh/wiki/Installing-ZSH)
* [oh-my-zsh](https://github.com/ohmyzsh/ohmyzsh)
## Installation
For the installation you need to
* Clone this project into `~/.oh-my-zsh/custom/plugins`.
* Let your user to execute nvm, usually achieved with `chmod 755 $NVM_DIR/nvm.sh`
## Configuration
After the installation you need to add `node-env-installer` in the `plugins = (...)` variable of your `.zshrc` file.
If you want the plugin to install all dependencies in your projects you can use the next command `echo "export ZSH_NPM_AUTOINSTALL='true'" >> ~/.zshrc`
This last command will set an environment variable that let know the plugin to install and update everytime there is a change in the `package.json` file.