Commit f1c7fdb3 authored by Vitaly Lipatov's avatar Vitaly Lipatov

epm play: sort installed apps, return status for update

parent cb45ff61
...@@ -93,7 +93,7 @@ __epm_play_list_installed() ...@@ -93,7 +93,7 @@ __epm_play_list_installed()
exit exit
fi fi
[ -n "$quiet" ] || echo "Installed applications:" [ -n "$quiet" ] || echo "Installed applications:"
for i in $(__list_installed_app) ; do for i in $(__list_installed_app | sort) ; do
local desc="$(__get_app_description $psdir/$i.sh)" local desc="$(__get_app_description $psdir/$i.sh)"
[ -n "$desc" ] || continue [ -n "$desc" ] || continue
[ -n "$quiet" ] || echo -n " " [ -n "$quiet" ] || echo -n " "
...@@ -172,17 +172,19 @@ if [ "$1" = "--update" ] ; then ...@@ -172,17 +172,19 @@ if [ "$1" = "--update" ] ; then
shift shift
if [ "$1" = "all" ] ; then if [ "$1" = "all" ] ; then
shift shift
RES=0
for i in $(__list_installed_app) ; do for i in $(__list_installed_app) ; do
echo echo
echo "$i" echo "$i"
prescription="$i" prescription="$i"
if ! __check_play_script $prescription ; then if ! __check_play_script $prescription ; then
warning "Can't find executable play script for $prescription. Try epm play --remove $prescription if you don't need it anymore." warning "Can't find executable play script for $prescription. Try epm play --remove $prescription if you don't need it anymore."
RES=1
continue continue
fi fi
__epm_play_run $prescription --run "$@" __epm_play_run $prescription --run "$@" || RES=$?
done done
exit exit $RES
fi fi
if [ -z "$1" ] ; then if [ -z "$1" ] ; then
fatal "run --update with 'all' or a project name" fatal "run --update with 'all' or a project name"
...@@ -201,7 +203,7 @@ if [ "$1" = "--installed" ] ; then ...@@ -201,7 +203,7 @@ if [ "$1" = "--installed" ] ; then
exit exit
fi fi
if [ "$1" = "--list" ] ; then if [ "$1" = "--list" ] || [ "$1" = "--list-installed" ] ; then
__epm_play_list_installed __epm_play_list_installed
exit exit
fi fi
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment