rockstardev
rockstardev

Reputation: 13537

How to see change brought on by a commit?

We have a GitBlit server, but if I log in, the UI doesn't really show me the change brought on by n commit. I was hoping there is some command like "git commit [HASH]" that shows you the change that was made by that commit.

Is there an easy way to see this?

Upvotes: 0

Views: 34

Answers (2)

Sandeep Kaul
Sandeep Kaul

Reputation: 3277

You can use the following

git show <commit-id>

It will show you the commit message and the diff.

Upvotes: 1

dpix
dpix

Reputation: 3113

git diff HEAD^ will show you the diff between current and last commit

git diff <HASH> will show you the diff between current and any commit

you can also use HEAD~3 to just go back 3 commits etc

Upvotes: 0

Related Questions