diff options
author | Daniel Friesel <derf@derf.homelinux.org> | 2008-06-27 20:05:31 +0200 |
---|---|---|
committer | Daniel Friesel <derf@derf.homelinux.org> | 2008-06-27 20:05:31 +0200 |
commit | 3438163d4ee72b876a06b1ceb967f9f6bd2ee492 (patch) | |
tree | b5080d64a86bebba1b5bab157862a46517e83bc4 | |
parent | a52bddd20225232de958aa1a73f4fab20367b4f4 (diff) |
bin/pkg: Renamed update to upgrade to support further upgrade commands
-rwxr-xr-x | bin/pkg | 14 | ||||
-rw-r--r-- | man/1/pkg | 6 |
2 files changed, 10 insertions, 10 deletions
@@ -136,7 +136,7 @@ vcs_log () { [ -d .git ] && {git log ; return} } -vcs_update () { +vcs_upgrade () { [ -d .hg ] && {hg pull --update ; return} [ -d .git ] && {git pull ; return} } @@ -319,7 +319,7 @@ pkg_remove () { info "Package removed.\n" } -pkg_update () { +pkg_upgrade () { check_installed "$1" cd $PDIR/$1 info "Looking for updates: $1" @@ -329,7 +329,7 @@ pkg_update () { info "Updating $1" [ -n "$NEW" ] && info " to $(echo $NEW | tail -n 1)" info "\n" - vcs_update + vcs_upgrade check_deps "$1" if ([ -r Makefile ]) { info "Building binaries\n" @@ -345,13 +345,13 @@ pkg_update () { } # If no package was specified, update everything -pkg_update_wrapper () { +pkg_upgrade_wrapper () { if ([ -n "$1" ]) { - pkg_update "$1" + pkg_upgrade "$1" } else { cd $PDIR for i in *(/); { - pkg_update "$i" + pkg_upgrade "$i" } } } @@ -492,6 +492,6 @@ case "$1" in log) pkg_log "$2" ;; remove) pkg_remove "$2" ;; status) pkg_status_wrapper "$2" ;; - update) pkg_update_wrapper "$2" ;; + upgrade) pkg_upgrade_wrapper "$2" ;; *) die "wait, what?\n" ;; esac @@ -62,7 +62,7 @@ Show commit history for package Check for local changes to the I<package>'s files. If no arguments is given, checks all installed packages -=item B<update> [ I<package> ] +=item B<upgrade> [ I<package> ] retrieve and install newest available version of I<package>. If no argument is given, updates all installed packages @@ -82,8 +82,8 @@ Contains configuration vars =head1 BUGS packages tracked in git are not completely supported. -'pkg update' will always try to update them, no matter whether there were -changed or not. Plus, the output of 'pkg update' will break a bit. +'pkg upgrade' will always try to update them, no matter whether there were +changed or not. Plus, the output of 'pkg upgrade' will break a bit. 'pkg changeroot' only works for hg packages. There might be more fail. |