0
npx create-react-app my-app

Creating a new React app in G:\project\my-app.

Installing packages. This might take a couple of minutes.
Installing react, react-dom, and react-scripts with cra-template...

'sh' is not recognized as an internal or external command,
operable program or batch file.

Aborting installation.
  yarnpkg add --exact react react-dom react-scripts cra-template --cwd G:\project\my-app has failed.

Deleting generated file... package.json
Deleting generated file... yarn.lock
Deleting my-app/ from G:\project
Done.

I have already tried clearing npm cache with npm clear cache --force. The same thing happens.

RobC
  • 22,977
  • 20
  • 73
  • 80
rathindu_w
  • 611
  • 1
  • 5
  • 12
  • Does this answer your question? ['sh' is not recognized as an internal or external command](https://stackoverflow.com/questions/64972826/sh-is-not-recognized-as-an-internal-or-external-command) – amirhe Jan 16 '21 at 14:42

1 Answers1

0

The problem was with my windows command prompt. When I used Git bash it worked perfectly.

rathindu_w
  • 611
  • 1
  • 5
  • 12