4

I know for Git Bash, you can use this command:git diff [--options] [--] [...] but I want to know if there is any way to find difference between a specific file using browser.

Like we can find changes in commits, but that includes all files (https://github.com/github/linguist/compare/c3a414e..faf7c6)

I just want to find changes to one specific file.

1
  • I haven't seen that option in the website. I might say that you cannot perform what you mentioned because you can only compare by branches, tags, commits, forks, and also time "doc". So in order to compare and just get one file you would need to compare by the file you want to see the changes. You might try using the Git Bash client, or any other client to get what you're asking for. Commented Jan 2, 2019 at 21:15

2 Answers 2

1

You can at least (through the browser) see commits which actually involved a given file.
For that, you need to access the "History" page of said file:

https://github.com/github/linguist/commits/master/lib/linguist/heuristics.rb

But that does not give you any diff between two commits.

Another workaround is at least to get to the blame view of that file.

https://github.com/github/linguist/blame/master/lib/linguist/heuristics.rb

For any diff shown here, you can click and see the previous revision information for that line, including who committed the change and when.

https://cloud.githubusercontent.com/assets/3477155/21945511/a5145ddc-d9a9-11e6-9723-85f8c498139b.gif

Sign up to request clarification or add additional context in comments.

Comments

0

git instaweb https://git-scm.com/docs/git-instaweb

NAME

git-instaweb - Instantly browse your working repository in gitweb
SYNOPSIS

git instaweb [--local] [--httpd=<httpd>] [--port=<port>]
               [--browser=<browser>]
git instaweb [--start] [--stop] [--restart]

Require: sudo apt install lighttpd

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.