tazpkg rev 71
Recharge automaticaly packages list if root and needed
author | Christophe Lincoln <pankso@slitaz.org> |
---|---|
date | Thu Apr 17 22:26:13 2008 +0200 (2008-04-17) |
parents | e0e65dcaa78d |
children | 93645e05c842 |
files | tazpkg |
line diff
1.1 --- a/tazpkg Sun Apr 13 11:39:25 2008 +0000 1.2 +++ b/tazpkg Thu Apr 17 22:26:13 2008 +0200 1.3 @@ -181,11 +181,15 @@ 1.4 check_for_packages_list() 1.5 { 1.6 if [ ! -f "$LOCALSTATE/packages.list" ]; then 1.7 - echo -e " 1.8 + if test $(id -u) = 0 ; then 1.9 + tazpkg recharge 1.10 + else 1.11 + echo -e " 1.12 Unable to find the list : $LOCALSTATE/packages.list\n 1.13 You must probably run 'tazpkg recharge' as root to get the last list of 1.14 packages avalaible on the mirror.\n" 1.15 - exit 0 1.16 + exit 0 1.17 + fi 1.18 fi 1.19 } 1.20