npm开始在tsc&&同时

时间:2016-08-19 20:38:32

标签: node.js angular npm typescript-typings tsc

我一直试图运行npm start并且我一直收到以下错误......

19 error node v4.2.0
20 error npm  v3.10.5
21 error code ELIFECYCLE
22 error resume-editor@1.0.0 start: `tsc && concurrently "npm run tsc:w" "npm run lite" `
22 error Exit status 1
23 error Failed at the resume-editor@1.0.0 start script 'tsc && concurrently "npm run tsc:w" "npm run lite" '.
23 error Make sure you have the latest version of node.js and npm installed.
23 error If you do, this is most likely a problem with the resume-editor package,
23 error not with npm itself.
23 error Tell the author that this fails on your system:
23 error     tsc && concurrently "npm run tsc:w" "npm run lite"
23 error You can get information on how to open an issue for this project with:
23 error     npm bugs resume-editor
23 error Or if that isn't available, you can get their info via:
23 error     npm owner ls resume-editor
23 error There is likely additional logging output above.
24 verbose exit [ 1, true ]

我尝试过以下方法: npm install tsc(&最新版本) npm install - 保存打字 打字安装 npm同时安装 npm安装 npm run typings npm run tsc(这里有错误)

似乎没有什么能让npm开始工作。 更令人困惑的是,在我退出并尝试运行node server.js之前,所有内容都运行良好。 然后,一旦我尝试切换回npm,我就一直收到这些错误。

的package.json:

{
  "name": "resume-editor",
  "version": "1.0.0",
  "scripts": {
    "start": "tsc && concurrently \"npm run tsc:w\" \"npm run lite\" ",
    "lite": "lite-server",
    "postinstall": "typings install",
    "tsc": "tsc",
    "tsc:w": "tsc -w",
    "typings": "typings"
  },
  "license": "ISC",
  "dependencies": {
    "@angular/common": "2.0.0-rc.4",
    "@angular/compiler": "2.0.0-rc.4",
    "@angular/core": "2.0.0-rc.4",
    "@angular/forms": "0.2.0",
    "@angular/http": "2.0.0-rc.4",
    "@angular/platform-browser": "2.0.0-rc.4",
    "@angular/platform-browser-dynamic": "2.0.0-rc.4",
    "@angular/router": "3.0.0-beta.1",
    "@angular/router-deprecated": "2.0.0-rc.2",
    "@angular/upgrade": "2.0.0-rc.4",
    "angular2-in-memory-web-api": "0.0.14",
    "body-parser": "^1.4.3",
    "bootstrap": "^3.3.6",
    "concurrently": "^2.2.0",
    "core-js": "^2.4.0",
    "express": "^4.13.4",
    "method-override": "^2.1.3",
    "mongoose": "^4.4.12",
    "morgan": "^1.1.1",
    "reflect-metadata": "^0.1.3",
    "rxjs": "5.0.0-beta.6",
    "systemjs": "0.19.27",
    "tsc": "^1.20150623.0",
    "typescript": "^1.8.10",
    "typings": "^1.3.2",
    "zone.js": "^0.6.12"
  },
  "devDependencies": {
    "concurrently": "^2.0.0",
    "lite-server": "^2.2.0",
    "typescript": "^1.8.10",
    "typings": "^1.0.4"
  }
}

P.S:我有节点和npm的最新版本。

3 个答案:

答案 0 :(得分:1)

您已经安装了一个名为TSC的软件包,它可能会与typescript软件包tsc中的命令行发生冲突。尝试卸载TSC包并重新运行

答案 1 :(得分:1)

您需要全局安装compat

typescript

答案 2 :(得分:0)

确保项目根目录的路径中没有空格。将祖先目录重命名为没有空格。