src is a directory not a file:  I tried npm start from one level up where 
is the package.json file  . tried npm start and got this error from the log

---log---

0 info it worked if it ends with ok

1 verbose cli [ '/usr/local/bin/node', '/usr/local/bin/npm', 'start' ]

2 info using [email protected]

3 info using [email protected]

4 verbose run-script [ 'prestart', 'start', 'poststart' ]

5 info lifecycle [email protected]~prestart: [email protected]

6 verbose lifecycle [email protected]~prestart: unsafe-perm in 
lifecycle true

7 verbose lifecycle [email protected]~prestart: PATH: 
/usr/local/lib/node_modules/npm/bin/node-gyp-bin:/Users/jrough/project/Demo/node_modules/.bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin

8 verbose lifecycle [email protected]~prestart: CWD: 
/Users/jrough/project/Demo

9 silly lifecycle [email protected]~prestart: Args: [ '-c', 'npm run 
build' ]

10 silly lifecycle [email protected]~prestart: Returned: code: 1  
signal: 
null

11 info lifecycle [email protected]~prestart: Failed to exec 
prestart script

12 verbose stack Error: [email protected] prestart: `npm run build`

12 verbose stack Exit status 1

12 verbose stack     at EventEmitter.<anonymous> 
(/usr/local/lib/node_modules/npm/lib/utils/lifecycle.js:283:16)

12 verbose stack     at emitTwo (events.js:106:13)

12 verbose stack     at EventEmitter.emit (events.js:194:7)

12 verbose stack     at ChildProcess.<anonymous> 
(/usr/local/lib/node_modules/npm/lib/utils/spawn.js:40:14)

12 verbose stack     at emitTwo (events.js:106:13)

12 verbose stack     at ChildProcess.emit (events.js:194:7)

12 verbose stack     at maybeClose (internal/child_process.js:899:16)

12 verbose stack     at Process.ChildProcess._handle.onexit 
(internal/child_process.js:226:5)

13 verbose pkgid [email protected]

14 verbose cwd /Users/jrough/project/Demo

15 verbose Darwin 16.6.0

16 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "start"

17 verbose node v7.10.0

18 verbose npm  v5.0.4

19 error code ELIFECYCLE

20 error errno 1

21 error [email protected] prestart: `npm run build`

21 error Exit status 1

22 error Failed at the [email protected] prestart script.

22 error This is probably not a problem with npm. There is likely 
additional logging output above.

23 verbose exit [ 1, true ]




---

sh-3.2# vi package.json


    "protractor": "protractor protractor.config.js",

    "pretest": "npm run build",

    "test": "concurrently \"npm run build:watch\" \"karma start 
karma.conf.js\"",

    "pretest:once": "npm run build",

    "test:once": "karma start karma.conf.js --single-run",

    "lint": "tslint ./src/**/*.ts -t verbose"

  },

  "keywords": [],

  "author": "",

  "license": "MIT",

  "dependencies": {

    "@angular/common": "~4.0.0",

    "@angular/compiler": "~4.0.0",

    "@angular/core": "~4.0.0",

    "@angular/forms": "~4.0.0",

    "@angular/http": "~4.0.0",

    "@angular/platform-browser": "~4.0.0",

    "@angular/platform-browser-dynamic": "~4.0.0",

    "@angular/router": "~4.0.0",


    "angular-in-memory-web-api": "~0.3.0",

    "systemjs": "0.19.40",

    "core-js": "^2.4.1",

    "rxjs": "5.0.1",

    "zone.js": "^0.8.4"

  },

  "devDependencies": {

    "concurrently": "^3.2.0",

    "lite-server": "^2.2.2",

    "typescript": "~2.1.0",


    "canonical-path": "0.0.2",

    "tslint": "^3.15.1",

    "lodash": "^4.16.4",

    "jasmine-core": "~2.4.1",

    "karma": "^1.3.0",

    "karma-chrome-launcher": "^2.0.0",

    "karma-cli": "^1.0.1",

    "karma-jasmine": "^1.0.2",

    "karma-jasmine-html-reporter": "^0.2.2",

    "protractor": "~4.0.14",

    "rimraf": "^2.5.4",


    "@types/node": "^6.0.46",

    "@types/jasmine": "2.5.36"

  },

  "repository": {}


this is the package.json file.  it is up one directory in the demo file. 
 There is no other files except package.json.

On Wednesday, July 5, 2017 at 4:06:37 PM UTC-7, Janis Rough wrote:
>
> I have installed lates update of npm.  I have done npm run build.    I 
> have enclosed the log.  Is it something to do with my export path?  see 
> lines between 9 and 10.  It should be reading the config file.   Also below 
> is my config file.   I don't know what to try. TIA
>
>
> ------log----
>
>  info it worked if it ends with ok
>
> 1 verbose cli [ '/usr/local/bin/node', '/usr/local/bin/npm', 'run', 
> 'build' ]
>
> 2 info using [email protected]
>
> 3 info using [email protected]
>
> 4 verbose run-script [ 'prebuild', 'build', 'postbuild' ]
>
> 5 info lifecycle [email protected]~prebuild: 
> [email protected]
>
> 6 silly lifecycle [email protected]~prebuild: no script for 
> prebuild, continuing
>
> 7 info lifecycle [email protected]~build: [email protected]
>
> 8 verbose lifecycle [email protected]~build: unsafe-perm in 
> lifecycle true
>
> 9 verbose lifecycle [email protected]~build: PATH: 
> /usr/local/lib/node_modules/npm/bin/node-gyp-bin:/Users/jrough/project/Demo/node_modules/.bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
>
> 10 verbose lifecycle [email protected]~build: CWD: 
> /Users/jrough/project/Demo
>
> 11 silly lifecycle [email protected]~build: Args: [ '-c', 'tsc -p 
> src/' ]
>
> 12 info lifecycle [email protected]~build: Failed to exec build 
> script
>
> 13 verbose stack Error: [email protected] build: `tsc -p src/`
>
> 13 verbose stack spawn ENOENT
>
> 13 verbose stack     at ChildProcess.<anonymous> 
> (/usr/local/lib/node_modules/npm/lib/utils/spawn.js:33:16)
>
> 13 verbose stack     at emitTwo (events.js:106:13)
>
> 13 verbose stack     at ChildProcess.emit (events.js:194:7)
>
> 13 verbose stack     at maybeClose (internal/child_process.js:899:16)
>
> 13 verbose stack     at Process.ChildProcess._handle.onexit 
> (internal/child_process.js:226:5)
>
> 14 verbose pkgid [email protected]
>
> 15 verbose cwd /Users/jrough/project/Demo/src
>
> 16 verbose Darwin 16.6.0
>
> 17 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "run" "build"
>
> 18 verbose node v7.10.0
>
> 19 verbose npm  v4.6.1
>
> 20 error file sh
>
> 21 error code ELIFECYCLE
>
> 22 error errno ENOENT
>
> 23 error syscall spawn
>
> 24 error [email protected] build: `tsc -p src/`
>
> 24 error spawn ENOENT
>
> 25 error Failed at the [email protected] build script.
>
>
> ----config----
>
> {
>
>   "name": "angular-quickstart",
>
>   "version": "1.0.0",
>
>   "description": "QuickStart package.json from the documentation, 
> supplemented with testing support",
>
>   "scripts": {
>
>     "build": "tsc -p src/",
>
>     "build:watch": "tsc -p src/ -w",
>
>     "build:e2e": "tsc -p e2e/",
>
>     "serve": "lite-server -c=bs-config.json",
>
>     "serve:e2e": "lite-server -c=bs-config.e2e.json",
>
>     "prestart": "npm run build",
>
>     "start": "concurrently \"npm run build:watch\" \"npm run serve\"",
>
>     "pree2e": "npm run build:e2e",
>
>     "e2e": "concurrently \"npm run serve:e2e\" \"npm run protractor\" 
> --kill-others --success first",
>
>     "preprotractor": "webdriver-manager update",
>
>     "protractor": "protractor protractor.config.js",
>
>     "pretest": "npm run build",
>
>     "test": "concurrently \"npm run build:watch\" \"karma start 
> karma.conf.js\"",
>
>     "pretest:once": "npm run build",
>
>     "test:once": "karma start karma.conf.js --single-run",
>
>     "lint": "tslint ./src/**/*.ts -t verbose"
>
>   },
>
>   "keywords": [],
>
>   "author": "",
>
>   "license": "MIT",
>
>   "dependencies": {
>
>     "@angular/common": "~4.0.0",
>
>     "@angular/compiler": "~4.0.0",
>
>     "@angular/core": "~4.0.0",
>
>     "@angular/forms": "~4.0.0",
>
>     "@angular/http": "~4.0.0",
>
>     "@angular/platform-browser": "~4.0.0",
>
>     "@angular/platform-browser-dynamic": "~4.0.0",
>
>     "@angular/router": "~4.0.0",
>
>
>     "angular-in-memory-web-api": "~0.3.0",
>
>     "systemjs": "0.19.40",
>
>     "core-js": "^2.4.1",
>
>     "rxjs": "5.0.1",
>
>     "zone.js": "^0.8.4"
>
>   },
>
>   "devDependencies": {
>
>     "concurrently": "^3.2.0",
>
>     "lite-server": "^2.2.2",
>
>     "typescript": "~2.1.0",
>
>
>     "canonical-path": "0.0.2",
>
>     "tslint": "^3.15.1",
>
>     "lodash": "^4.16.4",
>
>     "jasmine-core": "~2.4.1",
>
>     "karma": "^1.3.0",
>
>     "karma-chrome-launcher": "^2.0.0",
>
>     "karma-cli": "^1.0.1",
>
>     "karma-jasmine": "^1.0.2",
>
>     "karma-jasmine-html-reporter": "^0.2.2",
>
>     "protractor": "~4.0.14",
>
>     "rimraf": "^2.5.4",
>
>
>     "@types/node": "^6.0.46",
>
>     "@types/jasmine": "2.5.36"
>
>   },
>
>   "repository": {}
>
> }
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Angular and AngularJS discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to