From 01a3b7ad4464682c1d4319151ab7791f6f0a9dd8 Mon Sep 17 00:00:00 2001 From: tpearson Date: Sat, 3 Apr 2010 22:53:41 +0000 Subject: Made program functional again git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/kdpkg@1110662 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kdpkg-install/sh/kdpkg-sh | 39 +++++++++++++++++++++++++++++---------- 1 file changed, 29 insertions(+), 10 deletions(-) (limited to 'kdpkg-install/sh/kdpkg-sh') diff --git a/kdpkg-install/sh/kdpkg-sh b/kdpkg-install/sh/kdpkg-sh index e192a09..59b3ad1 100755 --- a/kdpkg-install/sh/kdpkg-sh +++ b/kdpkg-install/sh/kdpkg-sh @@ -1,12 +1,19 @@ -#!/bin/sh -# (C) Fabian Wuertz Feb 2008 +#!/bin/bash +# (c) 2010 Timothy Pearson +# (c) Fabian Wuertz Feb 2008 if [ "$1" == "update" ]; then apt-get update - echo "" - echo "Done! Press enter to continuo." - read + if [ $? -eq 0 ]; then + echo "" + echo "Update OK" + else + echo "" + echo "Errors were encountered while updating the package index" + echo "Please press enter to continue" + read + fi fi if [ "$1" == "install" ]; then @@ -19,10 +26,22 @@ if [ "$1" == "install" ]; then apt-get remove $removePackage fi dpkg -i $2 - apt-get install -f - echo "" - echo "Done! Press enter to continuo." - read + if [ $? -eq 0 ]; then + apt-get install -f + if [ $? -eq 0 ]; then + echo "" + echo "Installation OK" + else + echo "" + echo "Errors were encountered while installing your package" + echo "Please press enter to exit" + read + fi + else + echo "" + echo "Errors were encountered while installing your package" + echo "Please press enter to continue" + read + fi fi - -- cgit v1.2.1