0

I made changes to my code and typed:

git status

Which returned

Your branch is up-to-date with 'origin/branch_name'. nothing to commit, working directory clean

Then I typed

git diff

Which didn't print out anything...

Can someone help? It should be showing me files that were changed...

Thanks in advance!

Trung Tran
  • 13,141
  • 42
  • 113
  • 200

3 Answers3

1

Most likely you changed a file listed in .gitignore or .git/info/exclude. See Github's "Ignoring Files" documentation for more information.

Alternatively is it possible you already committed and pushed your changes? Check with git log or gitk (if installed).

Martin C.
  • 12,140
  • 7
  • 40
  • 52
0

When you type git status it compare the content of your working directory to the staging area and the staging are to the repository.

In your case all your files are commited so no changes are tracked.


Diff will print out the difference (content) of the changes which status only print summary

CodeWizard
  • 128,036
  • 21
  • 144
  • 167
0

git reset --soft HEAD^ solved the issue... i'm not 100% sure why.

Trung Tran
  • 13,141
  • 42
  • 113
  • 200