This problem is likely to happen because you are using Windows as your operating system. So on Windows, you can use GitBash for Git and the command line for Heroku.
Just try checking the git version from the command line in your directory, most likely the result will be 'git' not recognized.
So now, if you use Gitbash for git commands, this is the problem, because GitBash does not recognize Heroku.
When you enter the Heroku create command on the command line, it creates the application, but instead of returning a link to your project, it gives an error message like this: 'ENOENT: spawn git ENOENT',
If you try to enter Heroku commands in GitBash, they will not be recognized either.
Therefore, the only solution is to try to recognize Git from the command line by reinstalling Git and choosing Command Line
as the terminal instead of Bash . This may solve your problem.
source share