Git says "nothing to commit, working tree clean"

Viewed 65

I am trying to push a build to Git and I do the folowing:

git init
git add .
git commit -m "initial commit"

And then I get the message:

nothing to commit, working tree clean

I checked the ignored on git and added the build file.

What am I doing wrong?

2 Answers

After making changes to .gitignore file, do the following

git rm -r --cached .
git add .
git commit -m ".gitignore updated"

Then you can push git push or git push --force

Related