aboutsummaryrefslogtreecommitdiff
path: root/src/simplaret
diff options
context:
space:
mode:
Diffstat (limited to 'src/simplaret')
-rwxr-xr-xsrc/simplaret14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/simplaret b/src/simplaret
index 65d05aa..d6cded1 100755
--- a/src/simplaret
+++ b/src/simplaret
@@ -279,12 +279,18 @@ function simplaret_metafiles {
function simplaret_search {
- local priority message pattern
+ # search packages
+ # usage: simplaret_search [package-name] [-display_mode]
+ # display_mode can be any accepted by simplaret_show_package
+
+ local priority message pattern mode
if [ ! -z "$1" ] && ! echo $1 | grep -q -e "^-"; then
pattern="$1"
+ mode="$2"
else
pattern="-all"
+ mode="$1"
fi
for repos_type in patches root repos noarch; do
@@ -312,12 +318,12 @@ function simplaret_search {
# root repositories has ROOT_PRIORITY
for priority in $ROOT_PRIORITY; do
for file in `simplaret_find_package $pattern $storage/$repository_name | grep "/$priority/"`; do
- simplaret_show_package $file $2
+ simplaret_show_package $file $mode
done
done
else
for file in `simplaret_find_package $pattern $storage/$repository_name`; do
- simplaret_show_package $file $2
+ simplaret_show_package $file $mode
done
fi
@@ -496,7 +502,7 @@ function simplaret_get_jail_patches {
# grab patches from every other places
if [ "$CONSIDER_ALL_PACKAGES_AS_PATCHES" == "1" ]; then
- for candidate in `simplaret_search patches | grep -v patches | grep -v root`; do
+ for candidate in `simplaret_search patches -formatted | grep -v patches | grep -v root`; do
simplaret_search_and_download_patch
done
fi