#!/bin/bash
#================= Info ======================
# Simple desktop file to install rpm package, 
# or analyzed rpm package via right click.
# Notice: 
# It is not recomended to install packages 
# outside the repos for multiple reasons!
#
# Distro: PCLinuxOS
# Author: D.M-Wilhelm (leiche)
# Website: http://pclinuxos.com
# Licence: GPLv2
# Required: xterm, zenity, rpm
#=============================================
# Some variables
#  
ICON=/usr/share/icons/synaptic.png
usage ()
#
{
echo "No File"
exit 1 
}
#
if [ $# -eq 0 ];
then
usage
fi
#
RPM="$1"
#
# Read package 
#
rpm -qpl --queryformat 'Name         : %{Name}\nSummary   : %{Summary}\nHomepage : %{URL}\nLicense      : %{License}\nVersion       : %{Version}-%{Release}\n\nDescription:\n%{Description}\n\nFiles:\n' $RPM | zenity --text-info --title "$RPM" --width=400 --height=200 --window-icon=$ICON 
exit
