0
votes

I am using below data

  1. node - v6.11.3
  2. npm - 3.10.10
  3. protractor - 5.1.2

When i run the command

npm install protractor-jasmine2-screenshot-reporter --save-dev

it is displaying below error

no such file or directory, open 'C:\Users\agudla\package.json'

Full output

C:\Users\agudla>npm install protractor-jasmine2-screenshot-reporter --save-dev
npm WARN saveError ENOENT: no such file or directory, open 'C:\Users\agudla\package.json'
C:\Users\agudla
+-- UNMET PEER DEPENDENCY @angular/[email protected]
+-- [email protected]
`-- UNMET PEER DEPENDENCY tslint@>= 4 < 6

npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@^1.0.0 (node_modules\chokidar\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN enoent ENOENT: no such file or directory, open 'C:\Users\agudla\package.json'
npm WARN @angular/[email protected] requires a peer of @angular/[email protected] but none was installed.
npm WARN [email protected] requires a peer of tslint@>= 4 < 6 but none was installed.
npm WARN agudla No description
npm WARN agudla No repository field.
npm WARN agudla No README data
npm WARN agudla No license field.

Can anyone help me how to solve this error.

1
you could use Cliptor- an interactive cli for protractor, it sets up and download these kind of modules for you. - Ram Pasala

1 Answers

1
votes

you do not have any package.json file in your directory "C:\Users\agudla" .
Navigate in that directory and do a npm init which will create a package.json for you and then run npm install protractor-jasmine2-screenshot-reporter --save-dev

Refer this for more details: https://docs.npmjs.com/getting-started/creating-node-modules