[英]'.' is not recognized as internal or external command?
問題:
在我的 angular 項目中,我的 package.json 文件中有這些流動命令。
"scripts": {
"ng": "ng",
"start": "ng serve --open",
"start:prod": "npm run build:prod && npm run server",
"build": "ng build",
"build:prod": "ng build --prod",
"lint": "ng lint",
"test": "ng lint && ng test --configuration=test",
"watch": "ng test --configuration=test --browsers ChromeHeadless --watch --reporters dots",
"e2e": "ng e2e",
"e2e:ci": "ng e2e --webdriver-update false",
"pree2e:ci": "./node_modules/protractor/bin/webdriver-manager clean && ./node_modules/protractor/bin/webdriver-manager update --versions.chrome=62.0.3202",
"ci": "npm run format:test && ng lint && ng test --configuration=test --browsers ChromeTravisCi --code-coverage && npm run e2e:ci && npm run build:prod -- --deploy-url /angular-ngrx-material-starter/ --base-href /angular-ngrx-material-starter",
"format:write": "prettier projects/**/*.{ts,json,md,scss} --write",
"format:test": "prettier projects/**/*.{ts,json,md,scss} --list-different",
"release": "standard-version && git push --follow-tags origin master",
"analyze": "npm run build:prod -- --stats-json && webpack-bundle-analyzer ./dist/angular-ngrx-material-starter/stats-es2015.json",
"server": "node ./projects/server/server.js",
"contributors:add": "all-contributors add",
"contributors:generate": "all-contributors generate && node .all-contributors-html.js",
"contributors:check": "all-contributors check"
},
但是當我嘗試運行npm run pree2e:ci
時,它給了我這個錯誤。 .' is not recognized as an internal or external command,
.' is not recognized as an internal or external command,
. 我搜索了很多,但找不到正當理由。 當我在 bash 上點擊這個命令時,它正在工作。 ./node_modules/protractor/bin/webdriver-manager clean &&./node_modules/protractor/bin/webdriver-manager update --versions.chrome=62.0.3202
。 但是當我只運行 npm 運行命令時它不起作用。 有人可以幫我解決這個問題嗎? . 謝謝
你需要改變
"./node_modules/protractor/bin/webdriver-manager clean && ./node_modules/protractor/bin/webdriver-manager update --versions.chrome=62.0.3202"
通過查看文檔: 鏈接
"./node_modules/protractor/bin/webdriver-manager clean && ./node_modules/protractor/bin/webdriver-manager update --versions.chrome 62.0.3202"
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.