[kdiff3] /: Add --noauto option
Michael Reeves
null at kde.org
Wed Feb 26 00:16:30 GMT 2020
Git commit a90c16f93988e6531db546f8d4ac404673ab240a by Michael Reeves.
Committed on 21/02/2020 at 19:16.
Pushed by mreeves into branch 'master'.
Add --noauto option
Implement feature request for disabling --auto as git is hard coded to pass this.
BUG:176687
FIXED-IN:1.9
M +1 -0 doc/en/index.docbook
M +1 -0 doc/en/man-kdiff3.1.docbook
M +1 -1 src/kdiff3.cpp
M +2 -0 src/main.cpp
https://invent.kde.org/kde/kdiff3/commit/a90c16f93988e6531db546f8d4ac404673ab240a
diff --git a/doc/en/index.docbook b/doc/en/index.docbook
index 6841bcf..39f51b5 100644
--- a/doc/en/index.docbook
+++ b/doc/en/index.docbook
@@ -306,6 +306,7 @@ Options:
-b, --base file Explicit base file. For compatibility with certain tools.
-o, --output file Output file. Implies -m. E.g.: -o newfile.txt
--out file Output file, again. (For compatibility with certain tools.)
+ --noauto Ignore --auto and always show GUI.
--auto No GUI if all conflicts are auto-solvable. (Needs -o file)
--qall Don't solve conflicts automatically. (For compatibility...)
--L1 alias1 Visible name replacement for input file 1 (base).
diff --git a/doc/en/man-kdiff3.1.docbook b/doc/en/man-kdiff3.1.docbook
index c2c6080..4c66e81 100644
--- a/doc/en/man-kdiff3.1.docbook
+++ b/doc/en/man-kdiff3.1.docbook
@@ -35,6 +35,7 @@
<arg choice="opt"><option>-b, --base</option> <replaceable>file</replaceable></arg>
<arg choice="opt"><option>-o, --output</option> <replaceable>file</replaceable></arg>
<arg choice="opt"><option>--out</option> <replaceable>file</replaceable></arg>
+<arg choice="opt"><option>--noauto</option></arg>
<arg choice="opt"><option>--auto</option></arg>
<arg choice="opt"><option>--qall</option></arg>
<arg choice="opt"><option>-L1</option> <replaceable>alias1</replaceable></arg>
diff --git a/src/kdiff3.cpp b/src/kdiff3.cpp
index 22be5c8..64c0cf4 100644
--- a/src/kdiff3.cpp
+++ b/src/kdiff3.cpp
@@ -192,7 +192,7 @@ KDiff3App::KDiff3App(QWidget* pParent, const QString& name, KDiff3Part* pKDiff3P
m_sd3->setOptions(m_pOptions);
#ifdef ENABLE_AUTO
- m_bAutoFlag = hasArgs && KDiff3Shell::getParser()->isSet("auto");
+ m_bAutoFlag = hasArgs && KDiff3Shell::getParser()->isSet("auto") && !KDiff3Shell::getParser()->isSet("noauto");
#else
m_bAutoFlag = false;
#endif
diff --git a/src/main.cpp b/src/main.cpp
index f459463..ecbaa3c 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -114,7 +114,9 @@ int main(int argc, char* argv[])
cmdLineParser->addOption(QCommandLineOption(QLatin1String("out"), i18n("Output file, again. (For compatibility with certain tools.)"), QLatin1String("file")));
#ifdef ENABLE_AUTO
cmdLineParser->addOption(QCommandLineOption(QLatin1String("auto"), i18n("No GUI if all conflicts are auto-solvable. (Needs -o file)")));
+ cmdLineParser->addOption(QCommandLineOption(QLatin1String("noauto"), i18n("Ignore --auto and always show GUI.")));
#else
+ cmdLineParser->addOption(QCommandLineOption(QLatin1String("noauto"), i18n("Ignored.")));
cmdLineParser->addOption(QCommandLineOption(QLatin1String("auto"), i18n("Ignored.")));
#endif
cmdLineParser->addOption(QCommandLineOption(QLatin1String("qall"), i18n("Do not solve conflicts automatically.")));
More information about the kde-doc-english
mailing list