diff --git a/docs/diff-tool.md b/docs/diff-tool.md index 922347688a..8c0e4957da 100644 --- a/docs/diff-tool.md +++ b/docs/diff-tool.md @@ -80,8 +80,9 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins ## [Rider](https://www.jetbrains.com/rider/) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -92,7 +93,7 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%ProgramFiles%\JetBrains\JetBrains Rider *\bin\rider64.exe` -### Osx settings: +### OSX settings: **Example arguments:** ` diff "tempFile" "targetFile"` @@ -101,13 +102,11 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `/Applications/Rider*/Contents/MacOS/rider` -### Supported Text files: True - - ## [VisualStudio](https://docs.microsoft.com/en-us/visualstudio/ide/reference/diff) - * IsMdi: True - * SupportsAutoRefresh: True + * Is MDI: True + * Supports auto-refresh: True + * Supports text files: True ### Windows settings: @@ -120,13 +119,16 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Professional\Common7\IDE\devenv.exe` * `%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\devenv.exe` -### Supported Text files: True +## [VisualStudioCode](https://code.visualstudio.com) + + * Is MDI: True + * Supports auto-refresh: True + * Supports text files: True +### Notes: -## [VisualStudioCode](https://code.visualstudio.com/docs/editor/command-line) - * IsMdi: True - * SupportsAutoRefresh: True + * [Command line reference](https://code.visualstudio.com/docs/editor/command-line) ### Windows settings: @@ -137,7 +139,7 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%LOCALAPPDATA%\Programs\Microsoft VS Code\code.exe` -### Osx settings: +### OSX settings: **Example arguments:** `--diff "targetFile" "tempFile"` @@ -155,15 +157,13 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `/usr/local/bin/code` -### Supported Text files: True - - ## [TkDiff](https://sourceforge.net/projects/tkdiff/) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True -### Osx settings: +### OSX settings: **Example arguments:** `"tempFile" "targetFile"` @@ -172,13 +172,11 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `/Applications/TkDiff.app/Contents/MacOS/tkdiff` -### Supported Text files: True - - ## [KDiff3](https://github.com/KDE/kdiff3) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -189,7 +187,7 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%ProgramFiles%\KDiff3\kdiff3.exe` -### Osx settings: +### OSX settings: **Example arguments:** `"tempFile" "targetFile"` @@ -198,13 +196,11 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `/Applications/kdiff3.app/Contents/MacOS/kdiff3` -### Supported Text files: True - - ## [TortoiseIDiff](https://tortoisesvn.net/TortoiseIDiff.html) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: False ### Windows settings: @@ -215,9 +211,6 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%ProgramFiles%\TortoiseSVN\bin\TortoiseIDiff.exe` -### Supported Text files: False - - ### Supported binary extensions: * bmp @@ -231,8 +224,9 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins ## [TortoiseGitMerge](https://tortoisegit.org/docs/tortoisegitmerge/) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -243,13 +237,11 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%ProgramFiles%\TortoiseGit\bin\TortoiseGitMerge.exe` -### Supported Text files: True - - ## [TortoiseMerge](https://tortoisesvn.net/TortoiseMerge.html) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -260,13 +252,11 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%ProgramFiles%\TortoiseSVN\bin\TortoiseMerge.exe` -### Supported Text files: True - - ## [DiffMerge](https://www.sourcegear.com/diffmerge/) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -277,7 +267,7 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%ProgramFiles%\SourceGear\Common\DiffMerge\sgdm.exe` -### Osx settings: +### OSX settings: **Example arguments:** `--nosplash "tempFile" "targetFile"` @@ -295,13 +285,16 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `/usr/bin/diffmerge` -### Supported Text files: True +## [WinMerge](https://winmerge.org/) + + * Is MDI: False + * Supports auto-refresh: True + * Supports text files: True +### Notes: -## [WinMerge](https://manual.winmerge.org/en/Command_line.html) - * IsMdi: False - * SupportsAutoRefresh: True + * [Command line reference](https://manual.winmerge.org/en/Command_line.html) ### Windows settings: @@ -312,13 +305,16 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%ProgramFiles(x86)%\WinMerge\WinMergeU.exe` -### Supported Text files: True +## [CodeCompare](https://www.devart.com/codecompare/) + * Is MDI: True + * Supports auto-refresh: False + * Supports text files: True -## [CodeCompare](https://www.devart.com/codecompare/docs/index.html?comparing_via_command_line.htm) +### Notes: - * IsMdi: True - * SupportsAutoRefresh: False + + * [Command line reference](https://www.devart.com/codecompare/docs/index.html?comparing_via_command_line.htm) ### Windows settings: @@ -329,15 +325,13 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%ProgramFiles%\Devart\Code Compare\CodeCompare.exe` -### Supported Text files: True - - ## [Kaleidoscope](https://www.kaleidoscopeapp.com/) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True -### Osx settings: +### OSX settings: **Example arguments:** `"tempFile" "targetFile"` @@ -346,9 +340,6 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `/usr/local/bin/ksdiff` -### Supported Text files: True - - ### Supported binary extensions: * bmp @@ -362,8 +353,9 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins ## [SublimeMerge](https://www.sublimemerge.com/) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -374,7 +366,7 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%ProgramFiles%\Sublime Merge\smerge.exe` -### Osx settings: +### OSX settings: **Example arguments:** `mergetool "tempFile" "targetFile"` @@ -392,13 +384,11 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `/usr/bin/smerge` -### Supported Text files: True - - ## [Meld](https://meldmerge.org/) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -409,7 +399,7 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%ProgramFiles(x86)%\Meld\meld.exe` -### Osx settings: +### OSX settings: **Example arguments:** `"tempFile" "targetFile"` @@ -427,13 +417,19 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `/usr/bin/meld` -### Supported Text files: True +## [AraxisMerge](https://www.araxis.com/merge) + * Is MDI: True + * Supports auto-refresh: True + * Supports text files: True -## [AraxisMerge](https://www.araxis.com/merge) +### Notes: - * IsMdi: True - * SupportsAutoRefresh: True + + * [Supported image files](https://www.araxis.com/merge/documentation-windows/comparing-image-files.en) + * [Windows command line usage](https://www.araxis.com/merge/documentation-windows/command-line.en) + * [MacOS command line usage](https://www.araxis.com/merge/documentation-os-x/command-line.en) + * [Installing MacOS command line](https://www.araxis.com/merge/documentation-os-x/installing.en) ### Windows settings: @@ -444,17 +440,14 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%ProgramFiles%\Araxis\Araxis Merge\Compare.exe` -### Osx settings: +### OSX settings: -**Example arguments:** `/nowait "tempFile" "targetFile"` +**Example arguments:** `-nowait "tempFile" "targetFile"` **Scanned paths:** - * `/Applications/Araxis Merge.app/Contents/MacOS/Araxis Merge` - -### Supported Text files: True - + * `/Applications/Araxis Merge.app/Contents/Utilities/compare` ### Supported binary extensions: @@ -483,8 +476,9 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins ## [P4Merge](https://www.perforce.com/products/helix-core-apps/merge-diff-tool-p4merge) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -495,7 +489,7 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%ProgramFiles%\Perforce\p4merge.exe` -### Osx settings: +### OSX settings: **Example arguments:** `"tempFile" "targetFile"` @@ -513,9 +507,6 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `/usr/bin/p4merge` -### Supported Text files: True - - ### Supported binary extensions: * bmp @@ -531,10 +522,16 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * xbm * xpm -## [BeyondCompare](https://www.scootersoftware.com/v4help/index.html?command_line_reference.html) +## [BeyondCompare](https://www.scootersoftware.com) + + * Is MDI: False + * Supports auto-refresh: True + * Supports text files: True - * IsMdi: False - * SupportsAutoRefresh: True +### Notes: + + + * [Command line reference](https://www.scootersoftware.com/v4help/index.html?command_line_reference.html) ### Windows settings: @@ -546,7 +543,7 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `%ProgramFiles%\Beyond Compare 4\BCompare.exe` * `%ProgramFiles%\Beyond Compare 3\BCompare.exe` -### Osx settings: +### OSX settings: **Example arguments:** `/solo "tempFile" "targetFile"` @@ -564,9 +561,6 @@ This behavior is currently supported on Windows. On Linux and OSX, diff tool ins * `/usr/lib/beyondcompare/bcomp` -### Supported Text files: True - - ### Supported binary extensions: * mp3 diff --git a/src/DiffEngine.Tests/DiffToolsTest.cs b/src/DiffEngine.Tests/DiffToolsTest.cs index 2b51027084..2e5e03ae10 100644 --- a/src/DiffEngine.Tests/DiffToolsTest.cs +++ b/src/DiffEngine.Tests/DiffToolsTest.cs @@ -30,8 +30,9 @@ public void WriteFoundTools() ## [{tool.Name}]({tool.Url})"); writer.WriteLine($@" - * IsMdi: {tool.IsMdi} - * SupportsAutoRefresh: {tool.SupportsAutoRefresh}"); + * Is MDI: {tool.IsMdi} + * Supports auto-refresh: {tool.SupportsAutoRefresh} + * Supports text files: {tool.SupportsText}"); if (tool.Notes != null) { @@ -47,7 +48,7 @@ public void WriteFoundTools() ### Windows settings: "); writer.WriteLine($@" -**Example arguments:** `{tool.BuildWindowsArguments("tempFile", "targetFile")}`"); +**Example arguments:** `{tool.BuildWindowsArguments!("tempFile", "targetFile")}`"); writer.WriteLine(@" **Scanned paths:** @@ -61,10 +62,10 @@ public void WriteFoundTools() if (tool.OsxExePaths.Any()) { writer.WriteLine(@" -### Osx settings: +### OSX settings: "); writer.WriteLine($@" -**Example arguments:** `{tool.BuildOsxArguments("tempFile", "targetFile")}`"); +**Example arguments:** `{tool.BuildOsxArguments!("tempFile", "targetFile")}`"); writer.WriteLine(@" **Scanned paths:** @@ -81,7 +82,7 @@ public void WriteFoundTools() ### Linux settings: "); writer.WriteLine($@" -**Example arguments:** `{tool.BuildLinuxArguments("tempFile", "targetFile")}`"); +**Example arguments:** `{tool.BuildLinuxArguments!("tempFile", "targetFile")}`"); writer.WriteLine(@" **Scanned paths:** @@ -92,10 +93,6 @@ public void WriteFoundTools() } } - writer.WriteLine($@" -### Supported Text files: {tool.SupportsText} -"); - if (tool.BinaryExtensions.Any()) { writer.WriteLine(@" diff --git a/src/DiffEngine.Tests/diffTools.include.md b/src/DiffEngine.Tests/diffTools.include.md index 28e7999a4a..ef53e601a4 100644 --- a/src/DiffEngine.Tests/diffTools.include.md +++ b/src/DiffEngine.Tests/diffTools.include.md @@ -1,8 +1,9 @@ ## [Rider](https://www.jetbrains.com/rider/) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -13,7 +14,7 @@ * `%ProgramFiles%\JetBrains\JetBrains Rider *\bin\rider64.exe` -### Osx settings: +### OSX settings: **Example arguments:** ` diff "tempFile" "targetFile"` @@ -22,13 +23,11 @@ * `/Applications/Rider*/Contents/MacOS/rider` -### Supported Text files: True - - ## [VisualStudio](https://docs.microsoft.com/en-us/visualstudio/ide/reference/diff) - * IsMdi: True - * SupportsAutoRefresh: True + * Is MDI: True + * Supports auto-refresh: True + * Supports text files: True ### Windows settings: @@ -41,13 +40,16 @@ * `%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Professional\Common7\IDE\devenv.exe` * `%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\devenv.exe` -### Supported Text files: True +## [VisualStudioCode](https://code.visualstudio.com) + + * Is MDI: True + * Supports auto-refresh: True + * Supports text files: True +### Notes: -## [VisualStudioCode](https://code.visualstudio.com/docs/editor/command-line) - * IsMdi: True - * SupportsAutoRefresh: True + * [Command line reference](https://code.visualstudio.com/docs/editor/command-line) ### Windows settings: @@ -58,7 +60,7 @@ * `%LOCALAPPDATA%\Programs\Microsoft VS Code\code.exe` -### Osx settings: +### OSX settings: **Example arguments:** `--diff "targetFile" "tempFile"` @@ -76,15 +78,13 @@ * `/usr/local/bin/code` -### Supported Text files: True - - ## [TkDiff](https://sourceforge.net/projects/tkdiff/) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True -### Osx settings: +### OSX settings: **Example arguments:** `"tempFile" "targetFile"` @@ -93,13 +93,11 @@ * `/Applications/TkDiff.app/Contents/MacOS/tkdiff` -### Supported Text files: True - - ## [KDiff3](https://github.com/KDE/kdiff3) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -110,7 +108,7 @@ * `%ProgramFiles%\KDiff3\kdiff3.exe` -### Osx settings: +### OSX settings: **Example arguments:** `"tempFile" "targetFile"` @@ -119,13 +117,11 @@ * `/Applications/kdiff3.app/Contents/MacOS/kdiff3` -### Supported Text files: True - - ## [TortoiseIDiff](https://tortoisesvn.net/TortoiseIDiff.html) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: False ### Windows settings: @@ -136,9 +132,6 @@ * `%ProgramFiles%\TortoiseSVN\bin\TortoiseIDiff.exe` -### Supported Text files: False - - ### Supported binary extensions: * bmp @@ -152,8 +145,9 @@ ## [TortoiseGitMerge](https://tortoisegit.org/docs/tortoisegitmerge/) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -164,13 +158,11 @@ * `%ProgramFiles%\TortoiseGit\bin\TortoiseGitMerge.exe` -### Supported Text files: True - - ## [TortoiseMerge](https://tortoisesvn.net/TortoiseMerge.html) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -181,13 +173,11 @@ * `%ProgramFiles%\TortoiseSVN\bin\TortoiseMerge.exe` -### Supported Text files: True - - ## [DiffMerge](https://www.sourcegear.com/diffmerge/) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -198,7 +188,7 @@ * `%ProgramFiles%\SourceGear\Common\DiffMerge\sgdm.exe` -### Osx settings: +### OSX settings: **Example arguments:** `--nosplash "tempFile" "targetFile"` @@ -216,13 +206,16 @@ * `/usr/bin/diffmerge` -### Supported Text files: True +## [WinMerge](https://winmerge.org/) + + * Is MDI: False + * Supports auto-refresh: True + * Supports text files: True +### Notes: -## [WinMerge](https://manual.winmerge.org/en/Command_line.html) - * IsMdi: False - * SupportsAutoRefresh: True + * [Command line reference](https://manual.winmerge.org/en/Command_line.html) ### Windows settings: @@ -233,13 +226,16 @@ * `%ProgramFiles(x86)%\WinMerge\WinMergeU.exe` -### Supported Text files: True +## [CodeCompare](https://www.devart.com/codecompare/) + * Is MDI: True + * Supports auto-refresh: False + * Supports text files: True -## [CodeCompare](https://www.devart.com/codecompare/docs/index.html?comparing_via_command_line.htm) +### Notes: - * IsMdi: True - * SupportsAutoRefresh: False + + * [Command line reference](https://www.devart.com/codecompare/docs/index.html?comparing_via_command_line.htm) ### Windows settings: @@ -250,15 +246,13 @@ * `%ProgramFiles%\Devart\Code Compare\CodeCompare.exe` -### Supported Text files: True - - ## [Kaleidoscope](https://www.kaleidoscopeapp.com/) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True -### Osx settings: +### OSX settings: **Example arguments:** `"tempFile" "targetFile"` @@ -267,9 +261,6 @@ * `/usr/local/bin/ksdiff` -### Supported Text files: True - - ### Supported binary extensions: * bmp @@ -283,8 +274,9 @@ ## [SublimeMerge](https://www.sublimemerge.com/) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -295,7 +287,7 @@ * `%ProgramFiles%\Sublime Merge\smerge.exe` -### Osx settings: +### OSX settings: **Example arguments:** `mergetool "tempFile" "targetFile"` @@ -313,13 +305,11 @@ * `/usr/bin/smerge` -### Supported Text files: True - - ## [Meld](https://meldmerge.org/) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -330,7 +320,7 @@ * `%ProgramFiles(x86)%\Meld\meld.exe` -### Osx settings: +### OSX settings: **Example arguments:** `"tempFile" "targetFile"` @@ -348,13 +338,19 @@ * `/usr/bin/meld` -### Supported Text files: True +## [AraxisMerge](https://www.araxis.com/merge) + * Is MDI: True + * Supports auto-refresh: True + * Supports text files: True -## [AraxisMerge](https://www.araxis.com/merge) +### Notes: - * IsMdi: True - * SupportsAutoRefresh: True + + * [Supported image files](https://www.araxis.com/merge/documentation-windows/comparing-image-files.en) + * [Windows command line usage](https://www.araxis.com/merge/documentation-windows/command-line.en) + * [MacOS command line usage](https://www.araxis.com/merge/documentation-os-x/command-line.en) + * [Installing MacOS command line](https://www.araxis.com/merge/documentation-os-x/installing.en) ### Windows settings: @@ -365,17 +361,14 @@ * `%ProgramFiles%\Araxis\Araxis Merge\Compare.exe` -### Osx settings: +### OSX settings: -**Example arguments:** `/nowait "tempFile" "targetFile"` +**Example arguments:** `-nowait "tempFile" "targetFile"` **Scanned paths:** - * `/Applications/Araxis Merge.app/Contents/MacOS/Araxis Merge` - -### Supported Text files: True - + * `/Applications/Araxis Merge.app/Contents/Utilities/compare` ### Supported binary extensions: @@ -404,8 +397,9 @@ ## [P4Merge](https://www.perforce.com/products/helix-core-apps/merge-diff-tool-p4merge) - * IsMdi: False - * SupportsAutoRefresh: False + * Is MDI: False + * Supports auto-refresh: False + * Supports text files: True ### Windows settings: @@ -416,7 +410,7 @@ * `%ProgramFiles%\Perforce\p4merge.exe` -### Osx settings: +### OSX settings: **Example arguments:** `"tempFile" "targetFile"` @@ -434,9 +428,6 @@ * `/usr/bin/p4merge` -### Supported Text files: True - - ### Supported binary extensions: * bmp @@ -452,10 +443,16 @@ * xbm * xpm -## [BeyondCompare](https://www.scootersoftware.com/v4help/index.html?command_line_reference.html) +## [BeyondCompare](https://www.scootersoftware.com) + + * Is MDI: False + * Supports auto-refresh: True + * Supports text files: True - * IsMdi: False - * SupportsAutoRefresh: True +### Notes: + + + * [Command line reference](https://www.scootersoftware.com/v4help/index.html?command_line_reference.html) ### Windows settings: @@ -467,7 +464,7 @@ * `%ProgramFiles%\Beyond Compare 4\BCompare.exe` * `%ProgramFiles%\Beyond Compare 3\BCompare.exe` -### Osx settings: +### OSX settings: **Example arguments:** `/solo "tempFile" "targetFile"` @@ -485,9 +482,6 @@ * `/usr/lib/beyondcompare/bcomp` -### Supported Text files: True - - ### Supported binary extensions: * mp3 diff --git a/src/DiffEngine/Implementation/AraxisMerge.cs b/src/DiffEngine/Implementation/AraxisMerge.cs index 4309f95648..0a19e487dd 100644 --- a/src/DiffEngine/Implementation/AraxisMerge.cs +++ b/src/DiffEngine/Implementation/AraxisMerge.cs @@ -9,14 +9,20 @@ static partial class Implementation supportsAutoRefresh: true, isMdi: true, supportsText: true, - buildArguments: (tempFile, targetFile) => $"/nowait \"{tempFile}\" \"{targetFile}\"", + buildWindowsArguments: (tempFile, targetFile) => $"/nowait \"{tempFile}\" \"{targetFile}\"", + buildLinuxArguments: null, + buildOsxArguments: (tempFile, targetFile) => $"-nowait \"{tempFile}\" \"{targetFile}\"", windowsExePaths: new[] { @"%ProgramFiles%\Araxis\Araxis Merge\Compare.exe" }, + linuxExePaths: Array.Empty(), + osxExePaths: new[] + { + "/Applications/Araxis Merge.app/Contents/Utilities/compare" + }, binaryExtensions: new[] { - //https://www.araxis.com/merge/documentation-windows/comparing-image-files.en "bmp", "dib", "emf", @@ -40,9 +46,9 @@ static partial class Implementation "tga", "wmf", //? }, - linuxExePaths: Array.Empty(), - osxExePaths: new[] - { - "/Applications/Araxis Merge.app/Contents/MacOS/Araxis Merge" - }); + notes: @" + * [Supported image files](https://www.araxis.com/merge/documentation-windows/comparing-image-files.en) + * [Windows command line usage](https://www.araxis.com/merge/documentation-windows/command-line.en) + * [MacOS command line usage](https://www.araxis.com/merge/documentation-os-x/command-line.en) + * [Installing MacOS command line](https://www.araxis.com/merge/documentation-os-x/installing.en)"); } \ No newline at end of file diff --git a/src/DiffEngine/Implementation/BeyondCompare.cs b/src/DiffEngine/Implementation/BeyondCompare.cs index a60c60062e..6e20930e13 100644 --- a/src/DiffEngine/Implementation/BeyondCompare.cs +++ b/src/DiffEngine/Implementation/BeyondCompare.cs @@ -4,7 +4,7 @@ static partial class Implementation { public static ToolDefinition BeyondCompare() => new ToolDefinition( name: DiffTool.BeyondCompare, - url: "https://www.scootersoftware.com/v4help/index.html?command_line_reference.html", + url: "https://www.scootersoftware.com", supportsAutoRefresh: true, isMdi: false, supportsText: true, @@ -45,5 +45,7 @@ static partial class Implementation osxExePaths: new[] { "/Applications/Beyond Compare.app/Contents/MacOS/bcomp" - }); + }, + notes:@" + * [Command line reference](https://www.scootersoftware.com/v4help/index.html?command_line_reference.html)"); } \ No newline at end of file diff --git a/src/DiffEngine/Implementation/CodeCompare.cs b/src/DiffEngine/Implementation/CodeCompare.cs index 801ba5569d..c9206de7da 100644 --- a/src/DiffEngine/Implementation/CodeCompare.cs +++ b/src/DiffEngine/Implementation/CodeCompare.cs @@ -5,7 +5,7 @@ static partial class Implementation { public static ToolDefinition CodeCompare() => new ToolDefinition( name: DiffTool.CodeCompare, - url: "https://www.devart.com/codecompare/docs/index.html?comparing_via_command_line.htm", + url: "https://www.devart.com/codecompare/", supportsAutoRefresh: false, isMdi: true, supportsText: true, @@ -16,5 +16,7 @@ static partial class Implementation }, binaryExtensions: Array.Empty(), linuxExePaths: Array.Empty(), - osxExePaths: Array.Empty()); + osxExePaths: Array.Empty(), + notes:@" + * [Command line reference](https://www.devart.com/codecompare/docs/index.html?comparing_via_command_line.htm)"); } \ No newline at end of file diff --git a/src/DiffEngine/Implementation/VsCode.cs b/src/DiffEngine/Implementation/VsCode.cs index ae05f9603c..a099eadf33 100644 --- a/src/DiffEngine/Implementation/VsCode.cs +++ b/src/DiffEngine/Implementation/VsCode.cs @@ -5,7 +5,7 @@ static partial class Implementation { public static ToolDefinition VsCode() => new ToolDefinition( name: DiffTool.VisualStudioCode, - url: "https://code.visualstudio.com/docs/editor/command-line", + url: "https://code.visualstudio.com", supportsAutoRefresh: true, isMdi: true, supportsText: true, @@ -22,5 +22,7 @@ static partial class Implementation osxExePaths: new[] { "/Applications/Visual Studio Code.app/Contents/Resources/app/bin/code" - }); + }, + notes:@" + * [Command line reference](https://code.visualstudio.com/docs/editor/command-line)"); } \ No newline at end of file diff --git a/src/DiffEngine/Implementation/WinMerge.cs b/src/DiffEngine/Implementation/WinMerge.cs index c303e95937..f758c57e5a 100644 --- a/src/DiffEngine/Implementation/WinMerge.cs +++ b/src/DiffEngine/Implementation/WinMerge.cs @@ -5,7 +5,7 @@ static partial class Implementation { public static ToolDefinition WinMerge() => new ToolDefinition( name: DiffTool.WinMerge, - url: "https://manual.winmerge.org/en/Command_line.html", + url: "https://winmerge.org/", supportsAutoRefresh: true, isMdi: false, supportsText: true, @@ -16,5 +16,7 @@ static partial class Implementation }, binaryExtensions: Array.Empty(), linuxExePaths: Array.Empty(), - osxExePaths: Array.Empty()); + osxExePaths: Array.Empty(), + notes:@" + * [Command line reference](https://manual.winmerge.org/en/Command_line.html)"); } \ No newline at end of file diff --git a/src/DiffEngine/ToolDefinition.cs b/src/DiffEngine/ToolDefinition.cs index c84fe927ba..ef7e76a5ed 100644 --- a/src/DiffEngine/ToolDefinition.cs +++ b/src/DiffEngine/ToolDefinition.cs @@ -10,9 +10,9 @@ class ToolDefinition public string Url { get; } public bool SupportsAutoRefresh { get; } public bool IsMdi { get; } - public Func BuildWindowsArguments { get; } - public Func BuildLinuxArguments { get; } - public Func BuildOsxArguments { get; } + public Func? BuildWindowsArguments { get; } + public Func? BuildLinuxArguments { get; } + public Func? BuildOsxArguments { get; } public Func BuildArguments { @@ -20,17 +20,17 @@ public Func BuildArguments { if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows)) { - return BuildWindowsArguments; + return BuildWindowsArguments!; } if (RuntimeInformation.IsOSPlatform(OSPlatform.Linux)) { - return BuildLinuxArguments; + return BuildLinuxArguments!; } if (RuntimeInformation.IsOSPlatform(OSPlatform.OSX)) { - return BuildOsxArguments; + return BuildOsxArguments!; } throw new Exception($"OS not supported: {RuntimeInformation.OSDescription}"); @@ -46,6 +46,37 @@ public Func BuildArguments public string? Notes { get; } public bool SupportsText { get; } + public ToolDefinition( + DiffTool name, + string url, + bool supportsAutoRefresh, + bool isMdi, + bool supportsText, + Func? buildWindowsArguments, + Func? buildLinuxArguments, + Func? buildOsxArguments, + string[] windowsExePaths, + string[] binaryExtensions, + string[] linuxExePaths, + string[] osxExePaths, + string? notes = null) + { + Name = name; + Url = url; + SupportsAutoRefresh = supportsAutoRefresh; + IsMdi = isMdi; + BuildWindowsArguments = buildWindowsArguments; + BuildLinuxArguments = buildLinuxArguments; + BuildOsxArguments = buildOsxArguments; + BinaryExtensions = binaryExtensions; + WindowsExePaths = windowsExePaths; + LinuxExePaths = linuxExePaths; + OsxExePaths = osxExePaths; + Notes = notes; + SupportsText = supportsText; + + FindExe(); + } public ToolDefinition( DiffTool name, string url,