aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorrhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58>2007-01-10 16:03:52 +0000
committerrhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58>2007-01-10 16:03:52 +0000
commit246a539d7c3987cfaca3739b94dfb4a6f3dbe6ab (patch)
treee0d420d664ccf464edcebbc007285b6940a6543c /src
parent8bb0385f2a6d79d04bf9ae957245ae7786bc7ac6 (diff)
downloadsimplepkg-246a539d7c3987cfaca3739b94dfb4a6f3dbe6ab.tar.gz
simplepkg-246a539d7c3987cfaca3739b94dfb4a6f3dbe6ab.tar.bz2
simplaret:
--install checks if package file exist --get-patches now does a --update for each arch and version before get the patches git-svn-id: svn+slack://slack.fluxo.info/var/svn/simplepkg@86 04377dda-e619-0410-9926-eae83683ac58
Diffstat (limited to 'src')
-rwxr-xr-xsrc/simplaret8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/simplaret b/src/simplaret
index 8bf18ca..189d467 100755
--- a/src/simplaret
+++ b/src/simplaret
@@ -507,6 +507,8 @@ function simplaret_get_jail_patches {
VERSION="`default_version`"
ARCH="`default_arch`"
+ simplaret_update
+
# in case there's something wrong with the jail, abort
if [ -z "$VERSION" ] || [ -z "$ARCH" ]; then
return
@@ -603,7 +605,11 @@ function simplaret_install {
package="`simplaret_get $1 --silent`"
if [ "$?" == "0" ]; then
- $root upgradepkg --install-new $package
+ if [ -f "$package" ]; then
+ $root upgradepkg --install-new $package
+ else
+ echo "error: could not install package $package: file not found"
+ fi
else
echo "error: could not install package $package"
exit 1