"concurently" не распознается как внутренняя или внешняя команда, действующая программа или пакетный файл

Я пытаюсь запустить проект angular 2. Есть посылка.в JSON:

{
  "name": "angular2-quickstart",
  "version": "1.0.0",
  "scripts": {
    "start": "concurrently "npm run tsc:w" "npm run lite" ",
    "tsc": "tsc",
    "tsc:w": "tsc -w",
    "lite": "lite-server",
    "typings": "typings",
    "postinstall": "typings install"
  },
  "license": "ISC",
  "dependencies": {
    "angular2": "2.0.0-beta.7",
    "systemjs": "0.19.22",
    "es6-promise": "^3.0.2",
    "es6-shim": "^0.33.3",
    "reflect-metadata": "0.1.2",
    "rxjs": "5.0.0-beta.2",
    "zone.js": "0.5.15"
  },
  "devDependencies": {
    "concurrently": "^2.0.0",
    "lite-server": "^2.1.0",
    "typescript": "^1.8.2",
    "typings":"^0.6.8"
  }
}

Я бегу:

npm start

а я:

npm WARN package.json angular2-quickstart@1.0.0 No README.md file found!

> angular2-quickstart@1.0.0 start E:otherdropboxDropboxprogramavimaskodo pavyzdziaihtdocsangular_2egghead
> concurrently "npm run tsc:w" "npm run lite"

'concurrently' is not recognized as an internal or external command,
operable program or batch file.
npm ERR! angular2-quickstart@1.0.0 start: `concurrently "npm run tsc:w" "npm run lite" `
npm ERR! `cmd "/c" "concurrently "npm run tsc:w" "npm run lite" "` failed with 1
npm ERR!
npm ERR! Failed at the angular2-quickstart@1.0.0 start script.
npm ERR! This is most likely a problem with the angular2-quickstart package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     concurrently "npm run tsc:w" "npm run lite"
npm ERR! You can get their info via:
npm ERR!     npm owner ls angular2-quickstart
npm ERR! There is likely additional logging output above.

npm ERR! System Windows_NT 6.1.7601
npm ERR! command "C:Program Filesnodejsnode.exe" "C:Program Filesnodejsnode_modulesnpmbinnpm-cli.js" "start"
npm ERR! cwd E:otherdropboxDropboxprogramavimaskodo pavyzdziaihtdocsangular_2egghead
npm ERR! node -v v0.8.9
npm ERR! npm -v 1.1.61
npm ERR! code ELIFECYCLE
npm

Я тоже попробовал:

npm install -g concurrently

а также я получил ошибки:

npm http GET https://registry.npmjs.org/concurrently
npm http 304 https://registry.npmjs.org/concurrently
npm http GET https://registry.npmjs.org/concurrently/-/concurrently-2.0.0.tgz
npm http 200 https://registry.npmjs.org/concurrently/-/concurrently-2.0.0.tgz
npm http GET https://registry.npmjs.org/bluebird/2.9.6
npm http GET https://registry.npmjs.org/chalk/0.5.1
npm http GET https://registry.npmjs.org/commander/2.6.0
npm http GET https://registry.npmjs.org/cross-spawn
npm http GET https://registry.npmjs.org/lodash/3.1.0
npm http GET https://registry.npmjs.org/moment
npm http GET https://registry.npmjs.org/rx/2.3.24
npm http 200 https://registry.npmjs.org/cross-spawn
npm ERR! Error: No compatible version found: cross-spawn@'^0.2.9'
npm ERR! Valid install targets:
npm ERR! ["0.1.0","0.1.1","0.1.2","0.1.3","0.1.4","0.1.5","0.1.6","0.1.7","0.2.0","0.2.1","0.2.2","0.2.3","0.2.4","0.2.5","0.2.6","0.2.7","0.2.8","0.2.9","0.3.0","0.4.0","0.4.1","1.0.0","1.0.1","1.0.2","1.0.3","1.0.4","2.0.0","2.0.1","2.1.0","2.1.1","2.1.2","2.1.3","2.1.4","2.1.5"]
npm ERR!     at installTargetsError (C:Program Filesnodejsnode_modulesnpmlibcache.js:553:10)
npm ERR!     at C:Program Filesnodejsnode_modulesnpmlibcache.js:477:15
npm ERR!     at saved (C:Program Filesnodejsnode_modulesnpmnode_modulesnpm-registry-clientlibget.js:138:7)
npm ERR!     at C:Program Filesnodejsnode_modulesnpmnode_modulesgraceful-fsgraceful-fs.js:220:7
npm ERR!     at Object.oncomplete (fs.js:297:15)
npm ERR! If you need help, you may report this log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <npm-@googlegroups.com>

npm ERR! System Windows_NT 6.1.7601
npm ERR! command "C:Program Filesnodejsnode.exe" "C:Program Filesnodejsnode_modulesnpmbinnpm-cli.js" "install" "-g" "concurrently"
npm ERR! cwd E:otherdropboxDropboxprogramavimaskodo pavyzdziaihtdocsangular_2egghead
npm ERR! node -v v0.8.9
npm ERR! npm -v 1.1.61
npm http 200 https://registry.npmjs.org/moment
npm http 200 https://registry.npmjs.org/commander/2.6.0
npm http GET https://registry.npmjs.org/commander/-/commander-2.6.0.tgz
npm http 200 https://registry.npmjs.org/chalk/0.5.1
npm http GET https://registry.npmjs.org/chalk/-/chalk-0.5.1.tgz
npm http 200 https://registry.npmjs.org/bluebird/2.9.6
npm http GET https://registry.npmjs.org/bluebird/-/bluebird-2.9.6.tgz
npm http 200 https://registry.npmjs.org/commander/-/commander-2.6.0.tgz
npm http 200 https://registry.npmjs.org/chalk/-/chalk-0.5.1.tgz
npm http 200 https://registry.npmjs.org/bluebird/-/bluebird-2.9.6.tgz
npm http 200 https://registry.npmjs.org/rx/2.3.24
npm http 200 https://registry.npmjs.org/lodash/3.1.0
npm http GET https://registry.npmjs.org/lodash/-/lodash-3.1.0.tgz
npm http GET https://registry.npmjs.org/rx/-/rx-2.3.24.tgz
npm http 200 https://registry.npmjs.org/lodash/-/lodash-3.1.0.tgz
npm http 200 https://registry.npmjs.org/rx/-/rx-2.3.24.tgz
npm

возможно, я запускаю старую версию node. Я пытаюсь обновить:

npm install -g npm

и снова я получаю ошибки:

npm http GET https://registry.npmjs.org/npm
npm http 304 https://registry.npmjs.org/npm
npm http GET https://registry.npmjs.org/npm/-/npm-3.8.0.tgz
npm http 200 https://registry.npmjs.org/npm/-/npm-3.8.0.tgz
npm ERR! tar pack Error reading C:cygwintmpnpm-610857164431986-0.6791366613470018package
npm ERR! TypeError: Cannot call method 'filter' of undefined
npm ERR!     at Packer.IgnoreReader.addIgnoreRules (C:Program Filesnodejsnode_modulesnpmnode_modulesfstream-npmnode_modulesfstream-ignoreignore.js:148:13)
npm ERR!     at Packer.IgnoreReader.addIgnoreFile (C:Program Filesnodejsnode_modulesnpmnode_modulesfstream-npmnode_modulesfstream-ignoreignore.js:133:10)
npm ERR!     at fs.readFile (fs.js:176:14)
npm ERR!     at fs.close (C:Program Filesnodejsnode_modulesnpmnode_modulesgraceful-fsgraceful-fs.js:92:5)
npm ERR!     at Object.oncomplete (fs.js:297:15)
npm ERR! If you need help, you may report this log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <npm-@googlegroups.com>

npm ERR! System Windows_NT 6.1.7601
npm ERR! command "C:Program Filesnodejsnode.exe" "C:Program Filesnodejsnode_modulesnpmbinnpm-cli.js" "install" "-g" "npm"
npm ERR! cwd E:otherdropboxDropboxprogramavimaskodo pavyzdziaihtdocsangular_2egghead
npm ERR! node -v v0.8.9
npm ERR! npm -v 1.1.61
npm ERR! type non_object_property_call
npm ERR! addLocalDirectory Could not pack "C:cygwintmpnpm-61081457164431986-0.6791366613470018package" to "C:UsersDariusAppDataRoamingnpm-cachenpm3.8.0package.tgz"
npm ERR! SyntaxError: Unexpected end of input
npm ERR!     at Object.parse (native)
npm ERR!     at Packer.readRules (C:Program Filesnodejsnode_modulesnpmnode_modulesfstream-npmfstream-npm.js:189:33)
npm ERR!     at Packer.IgnoreReader.addIgnoreFile (C:Program Filesnodejsnode_modulesnpmnode_modulesfstream-npmnode_modulesfstream-ignoreignore.js:132:22)
npm ERR!     at fs.readFile (fs.js:176:14)
npm ERR!     at fs.close (C:Program Filesnodejsnode_modulesnpmnode_modulesgraceful-fsgraceful-fs.js:92:5)
npm ERR!     at Object.oncomplete (fs.js:297:15)
npm ERR! If you need help, you may report this log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <npm-@googlegroups.com>

npm ERR! System Windows_NT 6.1.7601
npm ERR! command "C:Program Filesnodejsnode.exe" "C:Program Filesnodejsnode_modulesnpmbinnpm-cli.js" "install" "-g" "npm"
npm ERR! cwd E:otherdropboxDropboxprogramavimaskodo pavyzdziaihtdocsangular_2egghead
npm ERR! node -v v0.8.9
npm ERR! npm -v 1.1.61
npm ERR! file C:cygwintmpnpm-610857164431986-0.6791366613470018packagenode_modulesread-package-treetestfixturesbadpackage.json
npm ERR! path C:cygwintmpnpm-610857164431986-0.6791366613470018packagenode_modulesread-package-treetestfixturesbad
npm ERR! type unexpected_eos
npm ERR! fstream_path C:cygwintmpnpm-610857164431986-0.6791366613470018packagenode_modulesread-package-treetestfixturesbad
npm ERR! fstream_type Directory
npm ERR! fstream_class Packer
npm ERR! fstream_stack Packer.readRules (C:Program Filesnodejsnode_modulesnpmnode_modulesfstream-npmfstream-npm.js:192:10)
npm ERR! fstream_stack Packer.IgnoreReader.addIgnoreFile (C:Program Filesnodejsnode_modulesnpmnode_modulesfstream-npmnode_modulesfstream-ignoreignore.js:132:22)
npm ERR! fstream_stack fs.readFile (fs.js:176:14)
npm ERR! fstream_stack fs.close (C:Program Filesnodejsnode_modulesnpmnode_modulesgraceful-fsgraceful-fs.js:92:5)
npm ERR! fstream_stack Object.oncomplete (fs.js:297:15)
npm

как исправить? Я не знаю, что еще добавить здесь.

2 ответов


после комментария rgvassar я попытался проверить шоколад. Я видел, что npm устарел здесь:

https://chocolatey.org/packages?q=npm

но я также видел, что npm поставляется с nodejs. Поэтому я решил обновить nodejs. После обновления nodejs я увидел, что npm также является обновлением.

затем я побежал в CMD как admin:

npm install -g concurrently

Я также видел, что npm не поддерживается на cygwin. Но поскольку cygwin также может обращаться к командам Windows cmd, я все еще могу использовать на нем, как я понимаю, просто нужно сделать установку на CMD.

Он был установлен успешно и теперь не выдает эту ошибку.

большое спасибо, особенно за быстрые комментарии!


npm install -g npm-windows-upgrade
npm install -g concurrently

это сработало для меня, при запуске cmd через admin