Heroku cannot find package.json during build, although I have

When I click on my node application for the heroku wizard, I get this log

remote: Building source:
remote:
remote: -----> App not compatible with buildpack: https://codon-
buildpacks.s3.amazonaws.com/buildpacks/heroku/nodejs.tgz
remote:        Node.js: package.json not found in application root

I can not find the reason why this happens, as I understood it in the root directory. I checked the use of git ls files and it appeared.

Is it possible that my application root does not match my repository root? How would I configure?

+4
source share
1 answer

It seems that when I click on the master hero, the main branch of my local repository pushes the heroics to the hero, and not to the branch in which I am now. So I needed to click:

git push heroku mybranchname:master

so that my branch (not the master) is clicked

+1
source

Source: https://habr.com/ru/post/1690909/


All Articles