From 8af535e31319056059e6aa339bbc20392cd5fd25 Mon Sep 17 00:00:00 2001 From: Artem Proskurnev Date: Fri, 18 Feb 2022 11:47:23 +0300 Subject: [PATCH] Chrome default, trigger preview plugins --- .../Home.desktop | 0 .../brandicons.filetrigger | 0 .../chromium.json | 0 .../inkscape.xml | 0 kometa-std-desktop-1.3/kdeglobals | 3 ++ .../previewplugins.filetrigger | 30 ++++++++++++++++++ .../trash.desktop | 0 .../Документ.ott | Bin .../Презентация.otp | Bin .../Таблица.ots | Bin kometa-std-desktop.spec | 22 ++++++++++--- 11 files changed, 50 insertions(+), 5 deletions(-) rename {kometa-std-desktop-1.1 => kometa-std-desktop-1.3}/Home.desktop (100%) rename {kometa-std-desktop-1.1 => kometa-std-desktop-1.3}/brandicons.filetrigger (100%) rename {kometa-std-desktop-1.1 => kometa-std-desktop-1.3}/chromium.json (100%) rename {kometa-std-desktop-1.1 => kometa-std-desktop-1.3}/inkscape.xml (100%) create mode 100644 kometa-std-desktop-1.3/kdeglobals create mode 100644 kometa-std-desktop-1.3/previewplugins.filetrigger rename {kometa-std-desktop-1.1 => kometa-std-desktop-1.3}/trash.desktop (100%) rename {kometa-std-desktop-1.1 => kometa-std-desktop-1.3}/Документ.ott (100%) rename {kometa-std-desktop-1.1 => kometa-std-desktop-1.3}/Презентация.otp (100%) rename {kometa-std-desktop-1.1 => kometa-std-desktop-1.3}/Таблица.ots (100%) diff --git a/kometa-std-desktop-1.1/Home.desktop b/kometa-std-desktop-1.3/Home.desktop similarity index 100% rename from kometa-std-desktop-1.1/Home.desktop rename to kometa-std-desktop-1.3/Home.desktop diff --git a/kometa-std-desktop-1.1/brandicons.filetrigger b/kometa-std-desktop-1.3/brandicons.filetrigger similarity index 100% rename from kometa-std-desktop-1.1/brandicons.filetrigger rename to kometa-std-desktop-1.3/brandicons.filetrigger diff --git a/kometa-std-desktop-1.1/chromium.json b/kometa-std-desktop-1.3/chromium.json similarity index 100% rename from kometa-std-desktop-1.1/chromium.json rename to kometa-std-desktop-1.3/chromium.json diff --git a/kometa-std-desktop-1.1/inkscape.xml b/kometa-std-desktop-1.3/inkscape.xml similarity index 100% rename from kometa-std-desktop-1.1/inkscape.xml rename to kometa-std-desktop-1.3/inkscape.xml diff --git a/kometa-std-desktop-1.3/kdeglobals b/kometa-std-desktop-1.3/kdeglobals new file mode 100644 index 0000000..cf4b296 --- /dev/null +++ b/kometa-std-desktop-1.3/kdeglobals @@ -0,0 +1,3 @@ +[General] +BrowserApplication=chromium.desktop +TerminalService=kf5-org.kde.konsole.desktop diff --git a/kometa-std-desktop-1.3/previewplugins.filetrigger b/kometa-std-desktop-1.3/previewplugins.filetrigger new file mode 100644 index 0000000..42565d4 --- /dev/null +++ b/kometa-std-desktop-1.3/previewplugins.filetrigger @@ -0,0 +1,30 @@ +#!/bin/sh +# +# RPM filetrigger for kde5 preview plugins. +# +# Copyright (C) 2021 Artem Proskurnev +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. + +mf='/usr/share/kf5/plasma/plasmoids/org.kde.desktopcontainment/contents/config/main.xml' +if egrep -qs $mf; +then + if [ -f $mf ]; + then + cat $mf > /tmp/main.xml + f="/tmp/main.xml" + g="/tmp/group.xml" + t="/tmp/tempmain.xml" + gstart=$(cat $f | grep -n "" | egrep -o "^[0-9]+") + awk "NR>=$gstart && NR<=$gend" $f > $g + awk "NR<$gstart" $f > $t + xmlstarlet edit -u "/group/entry[@name='previewPlugins']/default" -v "audiothumbnail,ffmpegthumbs,imagethumbnail,exrthumbnail,jpegthumbnail,windowsimagethumbnail,svgthumbnail,windowsexethumbnail,comicbookthumbnail,directorythumbnail,fontthumbnail,blenderthumbnail,rawthumbnail,ebookthumbnail" $g | awk "NR>1" >> $t + awk "NR>$gend" $f >> $t + sed -i "s//<\/default>/g" $t + mv -f $t $mf + fi +fi diff --git a/kometa-std-desktop-1.1/trash.desktop b/kometa-std-desktop-1.3/trash.desktop similarity index 100% rename from kometa-std-desktop-1.1/trash.desktop rename to kometa-std-desktop-1.3/trash.desktop diff --git a/kometa-std-desktop-1.1/Документ.ott b/kometa-std-desktop-1.3/Документ.ott similarity index 100% rename from kometa-std-desktop-1.1/Документ.ott rename to kometa-std-desktop-1.3/Документ.ott diff --git a/kometa-std-desktop-1.1/Презентация.otp b/kometa-std-desktop-1.3/Презентация.otp similarity index 100% rename from kometa-std-desktop-1.1/Презентация.otp rename to kometa-std-desktop-1.3/Презентация.otp diff --git a/kometa-std-desktop-1.1/Таблица.ots b/kometa-std-desktop-1.3/Таблица.ots similarity index 100% rename from kometa-std-desktop-1.1/Таблица.ots rename to kometa-std-desktop-1.3/Таблица.ots diff --git a/kometa-std-desktop.spec b/kometa-std-desktop.spec index 0e0e2bf..96e34b1 100644 --- a/kometa-std-desktop.spec +++ b/kometa-std-desktop.spec @@ -1,5 +1,5 @@ Name: kometa-std-desktop -Version: 1.1 +Version: 1.3 Release: kometa1 Summary: Kometa default desktop settings @@ -25,23 +25,28 @@ Default settings for applications %install %define skeldir "/etc/skel" +%define skelconfigdir "/etc/skel/.config" %define skeldesktopdir "/etc/skel/Рабочий стол" %define ftdir "/usr/lib/rpm" -mkdir -p %buildroot%skeldir/.config/inkscape -mkdir -p %buildroot%skeldir/.config/chromium/Default +mkdir -p %buildroot%skelconfigdir +mkdir -p %buildroot%skelconfigdir/inkscape +mkdir -p %buildroot%skelconfigdir/chromium/Default mkdir -p %buildroot%skeldesktopdir mkdir -p %buildroot%ftdir -install -pm644 inkscape.xml %buildroot%skeldir/.config/inkscape/preferences.xml -install -pm644 chromium.json %buildroot%skeldir/.config/chromium/Default/Preferences +install -pm644 kdeglobals %buildroot%skelconfigdir +install -pm644 inkscape.xml %buildroot%skelconfigdir/inkscape/preferences.xml +install -pm644 chromium.json %buildroot%skelconfigdir/chromium/Default/Preferences install -pm644 Home.desktop %buildroot%skeldesktopdir install -pm644 trash.desktop %buildroot%skeldesktopdir install -pm644 Документ.ott %buildroot%skeldesktopdir install -pm644 Таблица.ots %buildroot%skeldesktopdir install -pm644 Презентация.otp %buildroot%skeldesktopdir install -pm755 brandicons.filetrigger %buildroot%ftdir +install -pm755 previewplugins.filetrigger %buildroot%ftdir %files +"/etc/skel/.config/kdeglobals" "/etc/skel/.config/inkscape/preferences.xml" "/etc/skel/.config/chromium/Default/Preferences" "/etc/skel/Рабочий стол/Home.desktop" @@ -50,8 +55,15 @@ install -pm755 brandicons.filetrigger %buildroot%ftdir "/etc/skel/Рабочий стол/Презентация.otp" "/etc/skel/Рабочий стол/Таблица.ots" "/usr/lib/rpm/brandicons.filetrigger" +"/usr/lib/rpm/previewplugins.filetrigger" %changelog +* Thu Feb 17 2022 Artem Proskurnev 1.3-kometa1 +- KDE5 preview plugins + +* Wed Feb 16 2022 Artem Proskurnev 1.2-kometa1 +- Chromium - default + * Wed Dec 29 2021 Artem Proskurnev 1.1-kometa1 - Change Inkscape deafult theme. In a standard theme, icons are not visible on a dark background. Chromium <- yandex.ru