Comments (3)
This isn't possible I'm afraid. --ignore-matchine-lines
isn't passed to the external diff tool as far as I can see.
$ GIT_PAGER=cat DFT_LOG=trace GIT_EXTERNAL_DIFF=difft git diff --ignore-matching-lines 'app.kubernetes.io/version' --ext-diff
2024-01-28T20:32:00.303Z INFO difft::options > CLI arguments: ["src/conflicts.rs", "/tmp/git-blob-BI9V7X/conflicts.rs", "46602124597b3c0c7a20e89beee2a34ce9d376e1", "100644", "src/conflicts.rs", "0000000000000000000000000000000000000000", "100644"]
$ GIT_PAGER=cat DFT_LOG=trace GIT_EXTERNAL_DIFF=difft git diff --ext-diff
2024-01-28T20:32:55.768Z INFO difft::options > CLI arguments: ["src/conflicts.rs", "/tmp/git-blob-zpaXEJ/conflicts.rs", "46602124597b3c0c7a20e89beee2a34ce9d376e1", "100644", "src/conflicts.rs", "0000000000000000000000000000000000000000", "100644"]
Even if it was possible, I don't see how this feature could work for difftastic. Difftastic is diffing an abstract syntax tree (AST), and there's no way to apply a line-based exclude regex to an AST.
from difftastic.
Thank you for your answer @Wilfred
This isn't possible I'm afraid. --ignore-matchine-lines isn't passed to the external diff tool as far as I can see.
Maybe something to report to the git
project if you think it should be passed to the external diff tool, no?
Difftastic is diffing an abstract syntax tree (AST), and there's no way to apply a line-based exclude regex to an AST
I worked on AST for Java
& Kotlin
annotation processor, it was possible to filter out some cases when we had the AST representation. I don't want to presume about complexity of difftastic
, but a pre or post processing of the value could be possible, if not using the AST directly?
from difftastic.
there's no way to apply a line-based exclude regex to an AST
Would it be possible to apply the line-based exclude after the AST-diffing occurs, when it is rendered back to a text format?
from difftastic.
Related Issues (20)
- Error: "index out of bounds: the len is 20 but the index is 20" HOT 4
- Unchanged HTML reported as changed HOT 1
- No option to diff hidden files in directories HOT 1
- Word differ returns out-of-bounds column numbers HOT 1
- tree-sitter-lua is out-dated
- index out of bounds: the len is X but the index is X', src/display/inline.rs:115:21
- Bad error recovery from (incorrect) C preprocessor error
- Inline diff is ignoring unchanged lines between hunks
- "index out of bounds" error, panic in side_by_side.rs HOT 2
- Crash inside eshell with memory allocation error HOT 5
- Output file paths as relative to current working directory
- Feature Request: Compare Subdirectories, ignore directory name difference
- Elm diff shows no syntactic changes for changes to doc comments
- `--language` command line argument is not supported
- difft does shows single/double quote as a diff for python HOT 3
- Include line number in patch diff header
- difftastic do not show color in fzf preview
- Dynamic sublanguages (injections)
- [Question] Want to know the changes in the AST nodes of the old and new files? HOT 1
- Fix unused LinePosition on newer rustc
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from difftastic.