added exclude_apps and sort_app