summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndy Kluger2018-11-09 15:06:55 -0500
committerAndy Kluger2018-11-09 15:06:55 -0500
commit36a665b8540571c0acc4fd124071acbc0c63139d (patch)
tree80daa81d97a264e0d36f229da134444ad414878b
parentf52e2dcca419b52e415755e39f50e0595583e7ee (diff)
downloadaur-36a665b8540571c0acc4fd124071acbc0c63139d.tar.gz
version bump; move on up from sed to patch; use meld icon; work on 3 files as well as 2
-rw-r--r--.SRCINFO14
-rw-r--r--PKGBUILD15
-rw-r--r--dolphin-meld.patch60
3 files changed, 76 insertions, 13 deletions
diff --git a/.SRCINFO b/.SRCINFO
index b316a9732fc..bfb3d6fa14d 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,6 +1,6 @@
pkgbase = dolphin-meld
pkgdesc = KDE File Manager, using Meld rather than Kompare
- pkgver = 18.08.2
+ pkgver = 18.08.3
pkgrel = 1
url = https://kde.org/applications/system/dolphin/
arch = x86_64
@@ -23,14 +23,16 @@ pkgbase = dolphin-meld
optdepends = kdegraphics-thumbnailers: PDF and PS thumbnails
optdepends = konsole: terminal panel
optdepends = purpose: share context menu
- provides = dolphin=18.08.2
- conflicts = dolphin=18.08.2
- source = https://download.kde.org/stable/applications/18.08.2/src/dolphin-18.08.2.tar.xz
- source = https://download.kde.org/stable/applications/18.08.2/src/dolphin-18.08.2.tar.xz.sig
+ provides = dolphin=18.08.3
+ conflicts = dolphin=18.08.3
+ source = https://download.kde.org/stable/applications/18.08.3/src/dolphin-18.08.3.tar.xz
+ source = https://download.kde.org/stable/applications/18.08.3/src/dolphin-18.08.3.tar.xz.sig
+ source = dolphin-meld.patch
validpgpkeys = CA262C6C83DE4D2FB28A332A3A6A4DB839EAA6D7
validpgpkeys = F23275E4BF10AFC1DF6914A6DBD2CE893E2D1C87
- sha256sums = 5d79d289735822dfc27917917ee7c92284d1f846696773ed66da2102617e9451
+ sha256sums = 2bb4560979f8b3fe970bfdebea51b784cc3088ee4c3919bc5d9bf5eb5dfd916c
sha256sums = SKIP
+ sha256sums = 13107b72348bd7eea5665196dc4a37c21bff131bbc8457efe77ef8c3e9450c7b
pkgname = dolphin-meld
diff --git a/PKGBUILD b/PKGBUILD
index 7a465eeddd6..8fb963067ed 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -6,7 +6,7 @@
_pkgname=dolphin
pkgname=dolphin-meld
-pkgver=18.08.2
+pkgver=18.08.3
pkgrel=1
pkgdesc="KDE File Manager, using Meld rather than Kompare"
arch=(x86_64)
@@ -21,17 +21,18 @@ optdepends=('kde-cli-tools: for editing file type options' 'ffmpegthumbs: video
'ruby: installing new service menus from KDE Store' 'kdegraphics-thumbnailers: PDF and PS thumbnails'
'konsole: terminal panel' 'purpose: share context menu')
groups=(kde-applications kdebase)
-source=("https://download.kde.org/stable/applications/$pkgver/src/$_pkgname-$pkgver.tar.xz"{,.sig})
-sha256sums=('5d79d289735822dfc27917917ee7c92284d1f846696773ed66da2102617e9451'
- 'SKIP')
+source=("https://download.kde.org/stable/applications/$pkgver/src/$_pkgname-$pkgver.tar.xz"{,.sig}
+ "dolphin-meld.patch")
+sha256sums=('2bb4560979f8b3fe970bfdebea51b784cc3088ee4c3919bc5d9bf5eb5dfd916c'
+ 'SKIP'
+ '13107b72348bd7eea5665196dc4a37c21bff131bbc8457efe77ef8c3e9450c7b')
validpgpkeys=(CA262C6C83DE4D2FB28A332A3A6A4DB839EAA6D7 # Albert Astals Cid <aacid@kde.org>
F23275E4BF10AFC1DF6914A6DBD2CE893E2D1C87) # Christoph Feck <cfeck@kde.org>
prepare() {
mkdir -p build
- cd $_pkgname-$pkgver/src
- sed -i 's/kompare -c/meld/g' dolphinmainwindow.cpp
- sed -i 's/findExecutable(QStringLiteral("kompare")).isEmpty()/findExecutable(QStringLiteral("meld")).isEmpty()/g' dolphinmainwindow.cpp
+ cd $_pkgname-$pkgver
+ patch -p1 -i ../$pkgname.patch
}
build() {
diff --git a/dolphin-meld.patch b/dolphin-meld.patch
new file mode 100644
index 00000000000..f5b2ff5f913
--- /dev/null
+++ b/dolphin-meld.patch
@@ -0,0 +1,60 @@
+diff -ura dolphin-18.08.3.orig/src/dolphinmainwindow.cpp dolphin-18.08.3.new/src/dolphinmainwindow.cpp
+--- dolphin-18.08.3.orig/src/dolphinmainwindow.cpp 2018-11-09 14:38:47.556089139 -0500
++++ dolphin-18.08.3.new/src/dolphinmainwindow.cpp 2018-11-09 14:45:24.522392872 -0500
+@@ -273,7 +273,7 @@
+ const int selectedUrlsCount = m_tabWidget->currentTabPage()->selectedItemsCount();
+
+ QAction* compareFilesAction = actionCollection()->action(QStringLiteral("compare_files"));
+- if (selectedUrlsCount == 2) {
++ if (selectedUrlsCount == 2 || selectedUrlsCount == 3) {
+ compareFilesAction->setEnabled(isKompareInstalled());
+ } else {
+ compareFilesAction->setEnabled(false);
+@@ -705,7 +705,7 @@
+ void DolphinMainWindow::compareFiles()
+ {
+ const KFileItemList items = m_tabWidget->currentTabPage()->selectedItems();
+- if (items.count() != 2) {
++ if (items.count() != 2 && items.count() != 3) {
+ // The action is disabled in this case, but it could have been triggered
+ // via D-Bus, see https://bugs.kde.org/show_bug.cgi?id=325517
+ return;
+@@ -714,12 +714,18 @@
+ QUrl urlA = items.at(0).url();
+ QUrl urlB = items.at(1).url();
+
+- QString command(QStringLiteral("kompare -c \""));
++ QString command(QStringLiteral("meld \""));
+ command.append(urlA.toDisplayString(QUrl::PreferLocalFile));
+ command.append("\" \"");
+ command.append(urlB.toDisplayString(QUrl::PreferLocalFile));
+ command.append('\"');
+- KRun::runCommand(command, QStringLiteral("Kompare"), QStringLiteral("kompare"), this);
++ if (items.count() == 3) {
++ QUrl urlC = items.at(2).url();
++ command.append(" \"");
++ command.append(urlC.toDisplayString(QUrl::PreferLocalFile));
++ command.append('\"');
++ }
++ KRun::runCommand(command, QStringLiteral("Meld"), QStringLiteral("meld"), this);
+ }
+
+ void DolphinMainWindow::toggleShowMenuBar()
+@@ -1181,7 +1187,7 @@
+
+ QAction* compareFiles = actionCollection()->addAction(QStringLiteral("compare_files"));
+ compareFiles->setText(i18nc("@action:inmenu Tools", "Compare Files"));
+- compareFiles->setIcon(QIcon::fromTheme(QStringLiteral("kompare")));
++ compareFiles->setIcon(QIcon::fromTheme(QStringLiteral("meld")));
+ compareFiles->setEnabled(false);
+ connect(compareFiles, &QAction::triggered, this, &DolphinMainWindow::compareFiles);
+
+@@ -1576,7 +1582,7 @@
+ if (!initialized) {
+ // TODO: maybe replace this approach later by using a menu
+ // plugin like kdiff3plugin.cpp
+- installed = !QStandardPaths::findExecutable(QStringLiteral("kompare")).isEmpty();
++ installed = !QStandardPaths::findExecutable(QStringLiteral("meld")).isEmpty();
+ initialized = true;
+ }
+ return installed;