DWFILTER(1)
π DWFILTER(1) β reformat text for processing π
okay bestie, so dwfilter is a little program from the dwdiff family β manual page number one, section one, in case you were wondering β and honestly? she's giving glow-up assistant. let's get into it. π¦
β¨ NAME β¨
dwfilter β reformat text with dwdiff for further processing
πΈ SYNOPSIS πΈ
dwfilter [OPTIONS] OLD FILE NEW FILE POST PROCESSOR [POST PROCESSOR OPTIONS]
π DESCRIPTION π
So here's the vibe: dwfilter takes the text in the old file and reformats it according to what's in the new file (or the other way around, we'll get to that). Then it takes that freshly reformatted old file and the new file and shoves them both through a secondary filter. Two-for-one, iconic.
Why would you even want this? Because visual diff programs like meld and kdiff3 are amazing and you love them, but they get all dramatic when a text file has been reformatted after editing. dwfilter fixes that so you can still use them. fr fr.
Bonus use case: it lets you create small patches even when the new text has been reformatted. slay.
And for the reformatting part? dwfilter uses dwdiff. obviously. πββοΈ
π OPTIONS π
-r,--reverseβ flip the whole thing around: reformat the new file based on the contents of the old file, instead of the default where the old file gets reformatted based on the contents of the new file. main character energy, but backwards. π
and also β dwfilter accepts all of these dwdiff options:
-d delimiters,--delimiters=delimiters-P,--punctuation-W whitespace,--white-space=whitespace-i,--ignore-case-I,--ignore-formatting-D option,--diff-option=option-Cnum,--context=num-mnum,--match-context=num--aggregate-changes--wdiff-output-A algorithm,--algorithm=algorithm--profile=name,--no-profile
not me explaining all of these here tho β see the dwdiff manual page for the meaning. iykyk, bestie, i'm not doing the homework for you. π
file name tea: a single dash (-) as a file means standard input. only one file can be read from standard input, so don't get greedy. π
And if you've got file names that start with a dash and you don't want dwfilter mistaking them for options? just drop a double dash (--) and everything after it gets interpreted as files to read. problem solved, periodt. β¨
π BUGS π
If you think you've found a bug β first of all, deep breaths β please check that you're using the latest version of dwdiff at <http://os.ghalkes.nl/dwdiff.html>. π
When you report bugs, please include a minimal example that demonstrates the problem. like, the smallest possible thing that still breaks. help them help you, bestie. π«Ά
π AUTHOR π
G.P. Halkes <dwdiff@ghalkes.nl>
β COPYRIGHT β
Copyright Β© 2006-2010 G.P. Halkes
dwdiff is licensed under the GNU General Public License version 3. π
For more details on the license, see the file COPYING in the documentation directory. On Un*x systems this is usually /usr/share/doc/dwdiff-$VERSION$.
π¦ SEE ALSO π¦
dwdiff(1), diff(1), meld(1), kdiff3(1)
and that's the whole page, babe π β this was Version $VERSION$, dated 2018/12/06, and yes it's DWFILTER(1) all the way through. go forth and diff pretty. πβ¨πΈ
π¦ where this page comes from
- debian bookworm: dwdiff 2.1.4-2+b2 Β· GPL-3.0-or-later
- debian trixie: dwdiff 2.1.4-2+b3 Β· GPL-3.0-or-later
- nixos 26.05: dwdiff 2.1.4
- nixpkgs unstable: dwdiff 2.1.4
- ubuntu jammy: dwdiff 2.1.4-1build1 Β· GPL-3.0-or-later
- ubuntu noble: dwdiff 2.1.4-2build2 Β· GPL-3.0-or-later
- ubuntu questing: dwdiff 2.1.4-2build3
- ubuntu resolute: dwdiff 2.1.4-2build4 Β· GPL-3.0-or-later
- ubuntu stonking: dwdiff 2.1.4-2build4 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms