Questions tagged [git-diff]

Shows changes between the working tree and the committed contents of a git repository, or between two commits or branches of the repository.

git-diff(1) shows changes between the working tree and the committed contents of a git repository, or between two commits or branches of the repository.

It has a number of options to control which versions to diff and also how the produced diff output is formatted, see the man-page for details.

1085 questions
0
votes
2 answers

Beginner Git merge confuse about two branches

I am new to Git, and I'm confused. Here's an example: I build a repo called prj in my office. I add an image to it and commit to GitHub Later, when I back home, I clone this repo, check out a new branch (let's call it home) and replace this image…
Kuan
  • 11,149
  • 23
  • 93
  • 201
0
votes
1 answer

Compare committed revision with server one for the same branch

There is a basic question about revision compare in git. I can compare current version with original version with git diff HEAD^ HEAD However, I need compare current version (origin/master) with current version of same branch on git server. It was…
Loom
  • 9,768
  • 22
  • 60
  • 112
0
votes
2 answers

Git: Differences since a commit

Given this output: c:\git\xxx>git log --oneline -n 5 b99c981 Merge remote-tracking branch 'origin/xxx-newfeature' into xxx-blah e53f30a [maven-release-plugin] prepare for next development iteration e40978b [maven-release-plugin] prepare release…
Marcus Leon
  • 55,199
  • 118
  • 297
  • 429
0
votes
1 answer

How to create a new branch containing the difference between two other branches?

I have a project which contains code for multiples architectures. I copied motorola files into a different branch, I did likewise for MIPS... Basically project is complex and not well structured and i'm trying to understand it by applying divide and…
demofan
  • 1
  • 2
0
votes
1 answer

Git Diff Python: Python can't open file. Removes all '\' from directory

When I try to git diff a file using my custom python script I get the error can't open file and shows the directory with all '\' being removed. .gitconfig: [diff "zip"] textconv = python…
Hillboy
  • 472
  • 6
  • 19
0
votes
1 answer

How show which commit changed which line in diff

I want to show information in diff (or similar tool for git) which line in file was changed by which commit.
Marcin
  • 422
  • 6
  • 17
0
votes
2 answers

Git diff gone mad?

I'm trying to figure out what's going on with my local Git repo. I edit a file. Git reports everything has changed in the file (I only changed one line) At first I think "must be a newline problem", but it's not. I do a diff in TortoiseGit,…
dr Hannibal Lecter
  • 6,665
  • 4
  • 33
  • 42
0
votes
1 answer

Git diff with -m

I've a merge conflict, and when I do a git diff I'm shown diff in combined format. The documentation for git help diff, where it explains the combined diff format, it's mentioned that I could use -m with any of the diff commands. But git diff…
Jeenu
  • 2,109
  • 2
  • 20
  • 27
0
votes
1 answer

Report Showing Diff between 2 Commits

We are using git for TFS. I'm looking for something that can do essentially a git-diff on all commits between two dates and times. We know we can build something manually, but for compliance reasons, it's easier to get something through if it…
Jason N. Gaylord
  • 7,910
  • 15
  • 56
  • 95
0
votes
0 answers

git diff surrenders to new blocks having duplicate first or last lines

I often have these kind of results when using git diff: /* + * Newly added comment + */ + + + /* * Old comment */ This is technically correct (since the first line did not change) but makes the later commit…
PhilLab
  • 4,777
  • 1
  • 25
  • 77
0
votes
0 answers

Eclipse GIT plugin shows differences that don't exist

I'm using Eclipse GIT plugin (EGIT) to compare the entire master branch with another branch ("Compare With-->With branch, tag or reference)". The synchronize view shows many conflicts (with red double-arrows) but these files are absolutely equals…
0
votes
2 answers

Git: List the number of branches merged to Master but not on Release branch

I am using Git repository. I have a Release branch which is behind Master branch. I normally merged development branches to the Master and only QA verified branches merged to Release. Is there anyway to list out the branches which have been merged…
Paresh Masani
  • 7,474
  • 12
  • 73
  • 139
0
votes
0 answers

git diff output only line changes

I am trying to capture the differences across file changes by using git diff --exit-code --minimal the problem is that this generates too much output. Let's say I just add a new line on the beginning of the file, the rest remains the same…
Alg_D
  • 2,242
  • 6
  • 31
  • 63
0
votes
1 answer

Get the HEAD version of a given file for streaming processing/diffing

I'm generating a LaTeX document. I want to run a specialised latexdiff to compare my current (uncommitted) version against the last commit of a file, paper.tex. Something like: latexdiff paper.tex HEAD:paper.tex > diff.tex However I've got no idea…
Bolster
  • 7,460
  • 13
  • 61
  • 96
0
votes
1 answer

difr: how-to sbt build of difr

I would like to test and run the "difr" utility as described here : https://github.com/wspringer/difr But, I am getting the error below. Could you please advise on how to overcome this issue ? [info] Done…
nskalis
  • 2,232
  • 8
  • 30
  • 49