diff options
author | Daniel Friesel <derf@derf.homelinux.org> | 2008-10-24 19:20:06 +0200 |
---|---|---|
committer | Daniel Friesel <derf@derf.homelinux.org> | 2008-10-24 19:20:06 +0200 |
commit | f1cb10360b3c092b160cc75c56ef8228eff165df (patch) | |
tree | 983459254532b62b086af2b41a57408d6d6efcaa /bin/pkg | |
parent | 53aaf16641587b5f8ceb10575ff90e483c5a6f4b (diff) |
pkg update: Added 'package state' information
Diffstat (limited to 'bin/pkg')
-rwxr-xr-x | bin/pkg | 11 |
1 files changed, 10 insertions, 1 deletions
@@ -592,6 +592,14 @@ function pkg_info { if [[ -r description ]] { DESCRIPTION=$(cat description) } + state='installed' + if list_incoming $1; then + state+=', needs update' + else + state+=', up-to-date' + fi + } else { + state='not installed' } function show_info { @@ -601,7 +609,8 @@ function pkg_info { } show_info "Package" $NAME - show_info "Priority" "$PRIORITY ($PRIORITY_NAME)" + show_info 'State' $state + [[ -n $PRIORITY ]] && show_info "Priority" "$PRIORITY ($PRIORITY_NAME)" show_info "Local Version" $LOCAL_VERSION show_info "Remote Version" $REMOTE_VERSION show_info "Repository Type" $REPO_TYPE |