4,679 questions
2
votes
1
answer
61
views
How to compare the changes in two branches?
Say I have four commits A, B, C and D, with A being an ancestor of B and C being an ancestor of D. I now want to verify that the changes from A to B are the same as the changes from C to D (or show ...
0
votes
1
answer
38
views
Differential code coverage policy at folder level in ADO pull requests
I'm exploring the usage of azurepipelines-coverage.xml to enable differential code coverage policy.
I would like to know if this supports a sub-folder level target for differential code coverage.
I ...
0
votes
0
answers
42
views
How to compare XMLs and their nested content?
I have the following structure that I need to compare:
<ROOT>
<name>
<name>string</name>
<type>number</type>
<server>string</...
5
votes
3
answers
129
views
calculate diff to previous matching row in a dataframe
I have a series of timestamps (+ other data) that come from 2 separate streams of data ticking at different rates, an example below (NB: the frequency of the real data has some jitter so it's not a ...
2
votes
1
answer
214
views
Does Node.js have a built-in way to diff two strings?
I know there are third-party libraries for generating diffs in JavaScript, but I'm wondering if recent versions of Node.js include a native way to compare two strings and show their differences.
Is ...
2
votes
2
answers
124
views
Enable Code Coverage diff without a target/gate threshold in ADO
I have code coverage enabled and published in my ADO pull request pipeline. I'm looking at adding code coverage diff to it.
The Microsoft Learn Document doesn't mention how to fail a build if the ...
0
votes
1
answer
93
views
Detect renames with `git difftool --dir-diff`
With git difftool --dir-diff, I can 'diff a whole tree by preparing a temporary copy'. However, I then lose information about renames. Here's a comprehensive example demonstrating the same.
git init
...
0
votes
1
answer
51
views
How can I tell a file was renamed using pygit2
I am running a diff between 2 consecutive commits and the only change between them is a rename of one file without any change in content involved. If I run a show on the parent commit, I get this from ...
0
votes
0
answers
71
views
How to achieve "git diff --numstat" with additional moved lines stats
This is for a javascript app, so no UI needed.
My goal is to get stats of changes between 2 commits, basically exactly what git diff --numstat does, but also, along with the additions and deletions ...
0
votes
0
answers
15
views
How to compare 2-files at different locations
I have my project viewing explorer window under VSCode and I need to compare one of the file from that project to another which is opened from different location and it is not part of the project and ...
0
votes
0
answers
56
views
In GitKraken, when comparing against working directory, is there any way to get a writeable editor?
I have a stack of commits that I think I am ready to merge to main. I can easily right click on "origin/main" and select "Compare commit against working directory". This gives me a ...
3
votes
0
answers
93
views
Myers diff with a custom cost function
Myers diff algorithm treats insertion and removal equally at the same cost and treats equality at zero cost (free path).
I tried to alter this behavior with supplying a custom cost function which to ...
3
votes
0
answers
95
views
Modifying myers diff by identifying compound units and treating them as 1 single insertion or removal
Myers diff algorithm works at character level and identifies insertion, removal or no-operation at each step. So for example, comparing PQRSXRSYRSZ (old string presented horizontally) and PQRSARSXRSY (...
1
vote
0
answers
54
views
git blame only commits on feature-branch after master?
If I've branched off master onto feat-branch, can I run git blame on a file and only highlight/emphasize lines changed in commits after I diverged from master?
This would be helpful for when I am ...
1
vote
0
answers
104
views
SourceTree + PCB git diff tool (allspice.io)
I am using SourceTree latest version (as of 13/01/2025) v3.4.21 and I have a problem while using a third-party tool that helps me see grpahically the diffs between versions for PCB files in Altium (....
0
votes
1
answer
45
views
VS diffFile command does not show diff
Trying to compare 2 files from as adviced here Compare two files in Visual Studio
This only says new lines added (the + sign) , but does not show the diff , what can be wrong here ? Tried multiple ...
0
votes
0
answers
100
views
Git apply: how to ignore changes marked as "Binary files ... differ"?
I'm storing lots of deb's and rpm's as diffs from a few selected "seed" packages. The diffs are generated using git diff and applied using git apply. I only need the source files in the ...
0
votes
1
answer
80
views
Recreate exact output from this Linux diff command in a Windows System
I'm losing my mind trying to recreate the output of the following Linux command in a Windows Environment:
diff --old-line-format='%L' --new-line-format='' --unchanged-line-format='' file1 file2 | grep ...
0
votes
0
answers
208
views
How to compare the DIFF of two merges/merge requests with different bases
Is there a good way to compare the diff (so basically the diff of the diff) between two merges or even better two potential merges (aka merge requests).
For some context the branching pattern: There ...
0
votes
2
answers
88
views
How to tell with git whether an original commit that was reversed is the same as the new recommit?
Commit history looks like this
1. aaa original code
2. bbb the change
3. ccc unrelated change 1
4. ddd reversed bbb for some reason
5. eee unrelated change 2
Now code author wants to merge a PR ...
2
votes
1
answer
94
views
git log with all commits but partial diffs
I would like a way to log certain commits and also submit path arguments so that the diff on those paths, if any, is shown for each commit as if those path arguments were supplied like git diff -- <...
1
vote
0
answers
461
views
Automatically show diff of file and its swap file in neovim
When I have some work in neovim after it being closed without saving it will be stored in swap file. When I open the same file in neovim I am welcomed with this message:
E325: ATTENTION
Found a swap ...
1
vote
1
answer
51
views
Why doesn't mnemonicPrefix work when diff'ing a stash?
If I run
git -c diff.mnemonicprefix=true diff stash@{0} $(git branch --show-current)
the first line in the output is still
diff --git a/file.txt b/file.txt
as if I hadn't used diff.mnemonicPrefix.
...
0
votes
1
answer
498
views
Change in behaviour of Notepad++ plugins Compare and ComparePlus
The warning is: "Trying to compare files with different encodings - the result might be inaccurate and misleading. Compare anyway?"
The two files I'm comparing have been outputted from the ...
3
votes
0
answers
633
views
Revert line by line in VS Code diff / compare files
VS Code has a very useful diff tool for comparing files (e.g. through the select file -> compare with selected dialogs). I really like this tool and use it a lot, but often wish that I could "...