M.Svrcek
M.Svrcek

Reputation: 5645

Usage npm command after any command entered

i'm using cmder in win8.1. I have install node.js with npm. I have created alias for npm in cmder and when i am trying to check if it's ok, i use npm --version all i get is

npm config help

Usage: npm <command>

where <command> is one of:
    add-user, adduser, apihelp, author, bin, bugs, c, cache,
    completion, config, ddp, dedupe, deprecate, docs, edit,
    explore, faq, find, find-dupes, get, help, help-search,
    home, i, info, init, install, isntall, issues, la, link,
    list, ll, ln, login, ls, outdated, owner, pack, prefix,
    prune, publish, r, rb, rebuild, remove, repo, restart, rm,
    root, run-script, s, se, search, set, show, shrinkwrap,
    star, stars, start, stop, submodule, tag, test, tst, un,
    uninstall, unlink, unpublish, unstar, up, update, v,
    version, view, whoami

npm <cmd> -h     quick help on <cmd>
npm -l           display full usage info
npm faq          commonly asked questions
npm help <term>  search for help on <term>
npm help npm     involved overview

Specify configs in the ini-formatted file:
    C:\Users\svrcek\.npmrc
or on the command line via: npm <command> --key value
Config info can be viewed via: npm help config

[email protected] C:\Program Files\nodejs\node_modules\npm

Can someone help me where may be problem? All i found is that this is shown when invalid command is inserted, but i think it is valid

Upvotes: 3

Views: 5598

Answers (1)

donutello
donutello

Reputation: 653

You should try this alias:

alias npm=C:\Progra~2\nodejs\npm.cmd $* if you have "Program Files (x86)" or alias npm=C:\Progra~1\nodejs\npm.cmd $* if you have just "Program Files".

Upvotes: 2

Related Questions