Usage: diff2html [options] -- [diff args]
Options:
-s, --style Output style
[choices: "line", "side"] [default: "line"]
--synchronisedScroll, --sc Synchronised horizontal scroll
[boolean] [default: true]
--highlightCode, --hc Highlight Code [boolean] [default: true]
--summary, --su Show files summary
[choices: "closed", "open", "hidden"] [default: "closed"]
-d, --diffStyle Diff style
[choices: "word", "char"] [default: "word"]
--matching, --lm Diff line matching type
[choices: "lines", "words", "none"] [default: "none"]
--matchWordsThreshold, --lmt Diff line matching word threshold
[number] [default: 0.25]
--matchingMaxComparisons, --lmm Diff line matching maximum line
comparisons of a block of changes
[number] [default: 1000]
-f, --format Output format
[choices: "html", "json"] [default: "html"]
-i, --input Diff input source
[choices: "file", "command", "stdin"] [default: "command"]
-o, --output Output destination
[choices: "preview", "stdout"] [default: "preview"]
-u, --diffy Upload to diffy.org
[choices: "browser", "pbcopy", "print"]
-F, --file Send output to file (overrides output
option) [string]
--htmlWrapperTemplate, --hwt Use a custom template when generating
markup [string]
--ignore, --ig ignore a file [array] [default: []]
-h, -?, --help Show help [boolean]
-v, --version Show version number [boolean]
Examples:
diff2html -s line -f html -d word -i diff last commit, line by line, word
command -o preview -- -M HEAD~1 comparison between lines,previewed
in the browser and input from git
diff command
diff2html -i file -- my-file-diff.diff reading the input from a file
diff2html -f json -o stdout -- -M HEAD~1 print json format to stdout
diff2html -F my-pretty-diff.html -- -M print to file
HEAD~1
diff2html --ig package-lock.json ignore two particular files when
yarn.lock generating the diff
© 2014-2024 rtfpessoa
For more information, check out https://diff2html.xyz/
For support, check out https://github.com/rtfpessoa/diff2html-cli