From a5312cc759def71550c867b5e58451282bf4ac5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Terje=20R=C3=B8sten?= Date: Mon, 28 Aug 2017 19:40:55 +0200 Subject: [PATCH] Prefer lshw-gui in lshw-gui context --- lshw-gui | 2 +- lshw-gui.appdata.xml | 2 +- lshw.desktop => lshw-gui.desktop | 2 +- lshw.spec | 19 +++++++++++++------ org.ezix.lshw.gui.policy | 4 ++-- 5 files changed, 18 insertions(+), 11 deletions(-) rename lshw.desktop => lshw-gui.desktop (92%) diff --git a/lshw-gui b/lshw-gui index 8acf205..e36b3dd 100644 --- a/lshw-gui +++ b/lshw-gui @@ -1,5 +1,5 @@ #! /bin/bash -/usr/bin/pkexec /usr/sbin/gtk-lshw +/usr/bin/pkexec /usr/sbin/lshw-gui diff --git a/lshw-gui.appdata.xml b/lshw-gui.appdata.xml index ee69551..321d540 100644 --- a/lshw-gui.appdata.xml +++ b/lshw-gui.appdata.xml @@ -1,7 +1,7 @@ - gtk-lshw.desktop + lshw-gui.desktop GPL-2.0 CC0-1.0 LSHW diff --git a/lshw.desktop b/lshw-gui.desktop similarity index 92% rename from lshw.desktop rename to lshw-gui.desktop index 56b7867..517d78b 100644 --- a/lshw.desktop +++ b/lshw-gui.desktop @@ -4,7 +4,7 @@ Name=Hardware Lister Comment=Browse hardware on host computer StartupNotify=true Exec=/usr/bin/lshw-gui -Icon=lshw-logo +Icon=lshw-gui Terminal=false Type=Application Categories=GTK;System; diff --git a/lshw.spec b/lshw.spec index f7a1193..3a10baf 100644 --- a/lshw.spec +++ b/lshw.spec @@ -1,12 +1,12 @@ Summary: Hardware lister Name: lshw Version: B.02.18 -Release: 10%{?dist} +Release: 11%{?dist} License: GPLv2 Group: Applications/System URL: http://ezix.org/project/wiki/HardwareLiSter Source0: http://www.ezix.org/software/files/lshw-%{version}.tar.gz -Source1: lshw.desktop +Source1: lshw-gui.desktop Source2: org.ezix.lshw.gui.policy Source3: lshw-gui Source4: lshw-gui.appdata.xml @@ -66,7 +66,8 @@ make install-gui \ STRIP="/bin/true" \ INSTALL="install -p" -ln -s -f gtk-lshw %{buildroot}%{_sbindir}/lshw-gui +mv %{buildroot}%{_sbindir}/gtk-lshw %{buildroot}%{_sbindir}/lshw-gui +ln -s -f lshw-gui %{buildroot}%{_sbindir}/gtk-lshw # don't package these copies, use the ones from hwdata instead rm -f %{buildroot}%{_datadir}/%{name}/pci.ids @@ -78,7 +79,9 @@ rm -f %{buildroot}%{_datadir}/%{name}/manuf.txt # desktop icon install -D -m 0644 -p ./src/gui/artwork/logo.svg \ - %{buildroot}%{_datadir}/pixmaps/%{name}-logo.svg + %{buildroot}%{_datadir}/pixmaps/%{name}-gui.svg +install -D -m 0644 -p ./src/gui/artwork/logo.svg \ + %{buildroot}%{_datadir}/icons/hicolor/scalable/apps/%{name}-gui.svg desktop-file-install %{?vendortag:--vendor fedora} \ --dir %{buildroot}%{_datadir}/applications %{SOURCE1} @@ -111,12 +114,16 @@ appstream-util validate-relax --nonet %{buildroot}/%{_datadir}/appdata/*.appdata %{_sbindir}/gtk-%{name} %{_sbindir}/%{name}-gui %{_datadir}/%{name} -%{_datadir}/pixmaps/%{name}-logo.svg -%{_datadir}/applications/*%{name}.desktop +%{_datadir}/pixmaps/%{name}-gui.svg +%{_datadir}/icons/hicolor/scalable/apps/%{name}-gui.svg +%{_datadir}/applications/%{name}-gui.desktop %{_datadir}/appdata/%{name}-gui.appdata.xml %{_datadir}/polkit-1/actions/org.ezix.lshw.gui.policy %changelog +* Mon Aug 28 2017 Terje Rosten - B.02.18-11 +- Prefer lshw-gui in lshw-gui context + * Sun Aug 13 2017 Terje Rosten - B.02.18-10 - Add AppData bz#1476498 diff --git a/org.ezix.lshw.gui.policy b/org.ezix.lshw.gui.policy index 8f8ab29..aedefb6 100644 --- a/org.ezix.lshw.gui.policy +++ b/org.ezix.lshw.gui.policy @@ -8,13 +8,13 @@ Hardware Lister (lshw) - list hardware information Authentication is required to run lshw-gui - lshw-logo + lshw-gui no no auth_admin_keep - /usr/sbin/gtk-lshw + /usr/sbin/lshw-gui true