summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2011-07-20 20:48:43 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2011-07-20 20:48:43 +0000
commitd00adb62390af1772fa0af79f2a1d75c17f7531a (patch)
tree5a05f3cc75fc0899737c98299d661e881853e1f1
parent2011-07-20 Joel Sherrill <joel.sherrill@oarcorp.com> (diff)
downloadrtems-testing-d00adb62390af1772fa0af79f2a1d75c17f7531a.tar.bz2
2011-07-20 Joel Sherrill <joel.sherrill@oarcorp.com>
* mktest: Add option to put test number in.
-rw-r--r--cvs-helpers/ChangeLog4
-rwxr-xr-xcvs-helpers/mktest9
2 files changed, 11 insertions, 2 deletions
diff --git a/cvs-helpers/ChangeLog b/cvs-helpers/ChangeLog
index 66344fe..46422e6 100644
--- a/cvs-helpers/ChangeLog
+++ b/cvs-helpers/ChangeLog
@@ -1,3 +1,7 @@
+2011-07-20 Joel Sherrill <joel.sherrill@oarcorp.com>
+
+ * mktest: Add option to put test number in.
+
2011-01-28 Joel Sherrill <joel.sherrill@oarcorp.com>
* cvscommit: Now running Go tests on PowerPC (2/3 passing) and i386 (in
diff --git a/cvs-helpers/mktest b/cvs-helpers/mktest
index f2f048a..e837fd0 100755
--- a/cvs-helpers/mktest
+++ b/cvs-helpers/mktest
@@ -25,7 +25,7 @@ check_status()
usage()
{
- echo "$progname -s SOURCE -d DEST -D description [-v]"
+ echo "$progname -s SOURCE -d DEST -D description -n NUMBER [-v]"
echo " OR"
echo "$progname -c -d DEST"
cat <<EOF
@@ -40,14 +40,16 @@ addToCVS=no
source=
dest=
desc=
+testNum=
verbose=no
-while getopts cd:D:s:v OPT
+while getopts cd:D:s:n:v OPT
do
case "$OPT" in
c) addToCVS=`toggle ${addToCVS}` ;;
d) dest=$OPTARG ;;
D) desc=$OPTARG ;;
s) source=$OPTARG ;;
+ n) testNum=$OPTARG ;;
v) verbose=`toggle ${verbose}` ;;
*) usage ;;
esac
@@ -77,6 +79,8 @@ test "X${source}" != "X"
check_status $? No source provided
test -d "${source}"
check_status $? Source directory not present
+test "X${testNum}" != "X"
+check_status $? No test number provided
test ! -d ${dest}/CVS
check_status $? "Are you sure about ${dest}? Already a CVS directory in it"
@@ -106,6 +110,7 @@ do
sed -e "s/@LOWER@/${dest}/g" \
-e "s/@UPPER@/${destCaps}/g" \
-e "s/@DESC@/${desc}/g" \
+ -e "s/@TESTNUM@/${testNum}/g" \
<${s} >${d}
check_status $? "Unable to process ${d}"
fi