tazpkg rev 352
Install package from file managers (double-click).
author | Eric Joseph-Alexandre <erjo@slitaz.org> |
---|---|
date | Mon Jun 28 07:21:28 2010 +0200 (2010-06-28) |
parents | 4f41dee74425 |
children | f50e99d54383 |
files | applications/tazpkg-install.desktop tazpkgbox-install |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/applications/tazpkg-install.desktop Mon Jun 28 07:21:28 2010 +0200 1.3 @@ -0,0 +1,12 @@ 1.4 +[Desktop Entry] 1.5 +Encoding=UTF-8 1.6 +Name=Package install 1.7 +Name[fr]=Installation de paquet 1.8 +Comment=Manage software packages 1.9 +Exec=subox "tazpkgbox-install ""%f""" 1.10 +Icon=tazpkg 1.11 +NoDisplay=True 1.12 +Type=Application 1.13 +Terminal=false 1.14 +MimeType=application/x-tazpkg; 1.15 +Categories=System;
2.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 2.2 +++ b/tazpkgbox-install Mon Jun 28 07:21:28 2010 +0200 2.3 @@ -0,0 +1,47 @@ 2.4 +#!/bin/sh 2.5 +# 2.6 +# GTKdialog interface to SliTaz Packages Manager aka Tazpkg. Notes: 2.7 +# Notebook tab are vbox, tabs are used to indent and functions are 2.8 +# split and found in $LIB. 2.9 +# 2.10 +# (C) GNU gpl v3 - SliTaz GNU/Linux 2010. 2.11 +# 2.12 +VERSION=1.0 2.13 + 2.14 +export PKG="$@" 2.15 +export PKG_SHORT_NAME=$(basename $PKG) 2.16 + 2.17 + 2.18 +# Tazpkgbox is only for root. 2.19 +if test $(id -u) != 0 ; then 2.20 + exec subox tazpkgbox-install $PKG 2.21 + exit 0 2.22 +fi 2.23 + 2.24 + 2.25 + 2.26 +# English/French help dialog. 2.27 +export MAIN_DIALOG=" 2.28 +<window title=\"Tazpkg install\" icon-name=\"tazpkg\"> 2.29 +<vbox> 2.30 + <text use-markup=\"true\" width-chars=\"54\"> 2.31 + <label>\" 2.32 +Package <b>$PKG_SHORT_NAME</b> will be installed\" 2.33 + </label> 2.34 + </text> 2.35 + <hbox> 2.36 + <button ok> 2.37 + <action>xterm -T \"Install package \" -geometry 80x16+120+120 -e \"tazpkg install $PKG; sleep 2\"</action> 2.38 + <action type=\"closewindow\">\"\"</action> 2.39 + </button> 2.40 + <button cancel> 2.41 + <action type=\"closewindow\">HELP</action> 2.42 + </button> 2.43 + </hbox> 2.44 +</vbox> 2.45 +</window> 2.46 +" 2.47 + 2.48 +gtkdialog --center --program=MAIN_DIALOG >/dev/null 2.49 + 2.50 +exit 0