Home

Awesome

ZSH NPM Plugin

GitHub version

Build

A zsh plugin that add NPM custom alias

This is completely based on oh-my-zsh NPM plugin.

Installation

Using zinit

Add zinit light trystan2k/zsh-npm-plugin into .zshrc

Using zpm

Add zpm load trystan2k/zsh-npm-plugin into .zshrc

Using oh-my-zsh

Execute git clone https://github.com/trystan2k/zsh-npm-plugin ~/.oh-my-zsh/custom/plugins/zsh-npm-plugin. Add zsh-npm-plugin into plugins array in .zshrc

Using antigen

Add antigen bundle trystan2k/zsh-npm-plugin into .zshrc

Using zgen

Add zgen load trystan2k/zsh-npm-plugin into .zshrc

Aliases

AliasCommandDescripton
npmgnpm i -gInstall dependencies globally
npminpm iInstall dependencies locally
npmSnpm i -SInstall and save to dependencies in your package.json
npmDnpm i -DInstall and save to dev-dependencies in your package.json
npmEPATH="$(npm bin)":"$PATH"Run command from node_modules folder based on current directory
npmOnpm outdatedCheck which npm modules are outdated
npmVnpm -vCheck package versions
npmLnpm listList installed packages
npmL0npm ls --depth=0List top-level installed packages
npmlsgnpm list -gList installed packages globally
npmlsg0npm list -g --depth=0List top-level installed packages globally
npmstnpm startRun npm start
npmtnpm testRun npm test
npmRnpm runRun npm scripts
npmPnpm publishRun npm publish
npmNewnpm initRun npm init
npmclr!rm -rf ./node_modules/Clear node_modules in current directory
nre!npmclr! && npmiReinstall packages
npmFnpm searchSearch in the npm database