https://github.com/jrr997/zsh-nvm-auto-use
A zsh plugin that helps you execute `nvm use` automatically.
https://github.com/jrr997/zsh-nvm-auto-use
Last synced: 9 months ago
JSON representation
A zsh plugin that helps you execute `nvm use` automatically.
- Host: GitHub
- URL: https://github.com/jrr997/zsh-nvm-auto-use
- Owner: jrr997
- License: mit
- Created: 2024-06-12T07:51:50.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2024-06-13T03:18:48.000Z (over 1 year ago)
- Last Synced: 2024-12-28T21:52:02.280Z (11 months ago)
- Language: Shell
- Size: 4.88 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-zsh-plugins - nvm-auto-use (jrr997) - Automatically manages your Node.js versions with [nvm](https://github.com/nvm-sh/nvm) based on your current directory. (Plugins / ZSH on Windows)
- fucking-awesome-zsh-plugins - nvm-auto-use (jrr997) - Automatically manages your Node.js versions with <b><code> 89193⭐</code></b> <b><code> 9553🍴</code></b> [nvm](https://github.com/nvm-sh/nvm)) based on your current directory. (Plugins / ZSH on Windows)
README
# zsh-nvm-auto-use
[](https://opensource.org/licenses/MIT)
A ZSH plugin that automatically manages your Node.js versions using [NVM](https://github.com/nvm-sh/nvm) based on your current directory.
## Tired of manually switching Node versions?
This plugin helps you:
**Automatically switch Node.js versions:** When you `cd` into a directory, it automatically runs the `nvm use` command if you run it before, so you just need to run `nvm use` once for every directory.
## Installation
1. **Prerequisites:** Make sure you have [NVM (Node Version Manager)](https://github.com/nvm-sh/nvm) installed on your system.
2. **Clone or Download:**
- Clone this repository to your ZSH plugins directory:
```bash
git clone https://github.com/jrr997/zsh-nvm-auto-use.git $ZSH_CUSTOM/plugins/zsh-nvm-auto-use
```
- Or download the `zsh-nvm-auto-use.plugin.zsh` file and place it in your ZSH plugins directory.
3. **Enable the Plugin:** Add the plugin to your `.zshrc` file:
```zsh
# dirs that make plugin activate, $HOME by default
# export NVM_AUTO_USE_DIRS=( "/path/to/where" )
source $ZSH_CUSTOM/plugins/zsh-nvm-auto-use/nvm-auto-use.plugin.zsh
```