Please put a revision number in the subject so we know what's the latest one, eg: [PATCH v5] fstests: Tests can use any name now, not 3 digits only On Thu, Mar 26, 2015 at 02:35:33PM +0100, Jan Ťulák wrote: > Tests can use any name now, not 3 digits only. > (e.g. a test can be named "tests/generic/001-some-name") > > Names are limited to alphanumeric characters and dash and are always prefixed > with an unique id for easier identification of a specific patch. patch or test? > --- a/README > +++ b/README > @@ -205,7 +205,7 @@ Test script environment: > > Verified output: > > - Each test script has a numerical name, e.g. 007, and an associated > + Each test script has a name, e.g. 007, and an associated > verified output, e.g. 007.out. I think the naming scheme could be described in the README, probably in the "Creating new tests scripts:" section. > +if [[ "$REPLY" =~ ^[Yy]$ ]]; then You don't need to quote variables in the [[ ]] block as it's a builtin, unlike [ (in general). Also, [[ $variable = glob ]] does really match globs, so it's simple [[ $REPLY = [yY] ]] if you insist on using [[ . > + for found in `tail -n +$line $tdir/group | $AWK_PROG '{ print $1 }'`; do > + foundId=$(echo "$found" | tr - ' ' | $AWK_PROG '{ print $1 }') > + line=$((line+1)) > + if [ -z "$found" ] || [ "$found" == "#" ]; then > + continue > + elif [[ "$found" > "$name" ]] || [ "$foundId" -gt "$id" ]; then Bash guide advices not to use [[ ]] for arithmetic expressions, in favor of (( )). Besides, I find mixing [[ ]] and [ ] inconsistent, choose one. > + eof=0 > + break > + fi > + done -- To unsubscribe from this list: send the line "unsubscribe fstests" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html