From 69ad6e13b3730e4e127ba17ea3c486989d751e44 Mon Sep 17 00:00:00 2001 From: Stephen Rothwell Date: Sun, 27 May 2012 18:44:08 +1000 Subject: [PATCH] fetch_trees: only fetch trees on the command line if specified --- fetch_trees | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/fetch_trees b/fetch_trees index a69e96c..d22c662 100755 --- a/fetch_trees +++ b/fetch_trees @@ -8,7 +8,9 @@ get_field() awk -F ' ' '$3 == "'$1'" { print $'$2'; }' } -trees=$(grep -v '^#' ../real_control | awk -F ' ' '{ print $3 }') +trees="$@" +[ "$trees" ] || + trees=$(grep -v '^#' ../real_control | awk -F ' ' '{ print $3 }') for name in $trees; do type=$(get_field "$name" 2) -- 2.39.5