From 2c6b53d9e6a80987187c09dbd7a83a3ccc607aa8 Mon Sep 17 00:00:00 2001 From: Fazle Arefin Date: Thu, 11 Apr 2024 08:51:22 +1000 Subject: [PATCH] difft: add page (#12598) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * difft: add page * Update pages/common/difft.md Co-authored-by: Vítor Henrique <87824454+vitorhcl@users.noreply.github.com> * Update pages/common/difft.md Co-authored-by: Vítor Henrique <87824454+vitorhcl@users.noreply.github.com> * Update pages/common/difft.md Co-authored-by: Vítor Henrique <87824454+vitorhcl@users.noreply.github.com> * Update pages/common/difft.md Co-authored-by: Vítor Henrique <87824454+vitorhcl@users.noreply.github.com> * Update pages/common/difft.md Co-authored-by: Vítor Henrique <87824454+vitorhcl@users.noreply.github.com> * Update pages/common/difft.md Co-authored-by: Vítor Henrique <87824454+vitorhcl@users.noreply.github.com> * Update pages/common/difft.md Co-authored-by: Vítor Henrique <87824454+vitorhcl@users.noreply.github.com> * Update pages/common/difft.md Co-authored-by: Vítor Henrique <87824454+vitorhcl@users.noreply.github.com> * Update pages/common/difft.md Co-authored-by: Vítor Henrique <87824454+vitorhcl@users.noreply.github.com> * difft: fix example description * Update pages/common/difft.md * difft: update description for compared files --------- Co-authored-by: Vítor Henrique <87824454+vitorhcl@users.noreply.github.com> --- pages/common/difft.md | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 pages/common/difft.md diff --git a/pages/common/difft.md b/pages/common/difft.md new file mode 100644 index 0000000000..968467f343 --- /dev/null +++ b/pages/common/difft.md @@ -0,0 +1,33 @@ +# difft + +> Compare files or directories based on the syntax of the programming language. +> See also: `delta`, `diff`. +> More information: . + +- Compare two files or directories: + +`difft {{path/to/file_or_directory1}} {{path/to/file_or_directory2}}` + +- Only report the presence of differences between the files: + +`difft --check-only {{path/to/file1}} {{path/to/file2}}` + +- Specify the display mode (default is `side-by-side`): + +`difft --display {{side-by-side|side-by-side-show-both|inline|json}} {{path/to/file1}} {{path/to/file2}}` + +- Ignore comments when comparing: + +`difft --ignore-comments {{path/to/file1}} {{path/to/file2}}` + +- Enable/Disable syntax highlighting of source code (default is `on`): + +`difft --syntax-highlight {{on|off}} {{path/to/file1}} {{path/to/file2}}` + +- Do not output anything at all if there are no differences between files: + +`difft --skip-unchanged {{path/to/file_or_directory1}} {{path/to/file_or_directory2}}` + +- Print all programming languages supported by the tool, along with their extensions: + +`difft --list-languages`