diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 2010-06-21 16:50:58 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 2010-06-21 16:50:58 +0000 |
commit | df40b83e182de12c7071ce843394b999341bdc12 (patch) | |
tree | 6339b28f0e873081bb829a9377f3f07a0a472b6c | |
parent | 2010-06-21 Joel Sherrill <joel.sherrill@oarcorp.com> (diff) | |
download | rtems-testing-df40b83e182de12c7071ce843394b999341bdc12.tar.bz2 |
2010-06-21 Joel Sherrill <joel.sherrill@oarcorp.com>
* mktest: Add generation of .cvsignore and first attempt at cvs add.
-rw-r--r-- | cvs-helpers/ChangeLog | 4 | ||||
-rwxr-xr-x | cvs-helpers/mktest | 31 |
2 files changed, 32 insertions, 3 deletions
diff --git a/cvs-helpers/ChangeLog b/cvs-helpers/ChangeLog index f2bc7e7..652f800 100644 --- a/cvs-helpers/ChangeLog +++ b/cvs-helpers/ChangeLog @@ -1,5 +1,9 @@ 2010-06-21 Joel Sherrill <joel.sherrill@oarcorp.com> + * mktest: Add generation of .cvsignore and first attempt at cvs add. + +2010-06-21 Joel Sherrill <joel.sherrill@oarcorp.com> + * Makefile: Add RTEMS test templates and test instantiator. * mktest: New file. diff --git a/cvs-helpers/mktest b/cvs-helpers/mktest index 492b037..845fb42 100755 --- a/cvs-helpers/mktest +++ b/cvs-helpers/mktest @@ -29,13 +29,15 @@ usage() exit 1 } +addToCVS=no source= dest= desc= verbose=no -while getopts d:D:s:v OPT +while getopts cd:D:s:v OPT do case "$OPT" in + c) addToCVS=`toggle ${addToCVS}` ;; d) dest=$OPTARG ;; D) desc=$OPTARG ;; s) source=$OPTARG ;; @@ -47,12 +49,30 @@ done # Error check test "X${dest}" != "X" check_status $? No destination provided +test -r configure.ac +check_status $? Not in test suite directory + + +if [ ${addToCVS} == yes ] ; then + test -d ${dest} + check_status $? "Cannot add ${dest} -- does not exist" + + echo cvs add ${dest} + cd ${dest} + for f in `ls -1 .cvsignore Makefile.am *.doc *.scn *.[ch] 2>/dev/null` + do + echo cvs add ${f} + done + exit 0 +fi + test "X${source}" != "X" check_status $? No source provided test -d "${source}" check_status $? Source directory not present -test -r configure.ac -check_status $? Not in test suite directory + +test -d ${dest}/CVS +check_status $? "Are you sure about ${dest}? Already a CVS directory in it" let $((shiftcount = $OPTIND - 1)) shift #shiftcount @@ -84,6 +104,11 @@ do fi done +cat <<EOF >${dest}/.cvsignore +Makefile +Makefile.in +EOF + cat <<EOF You need to add the test to the Makefile.am and configure.ac by hand before you can build. |