[DRBD-cvs] testing by lars; autodetection whether this can be intera...
drbd-user@lists.linbit.com
drbd-user@lists.linbit.com
Fri, 28 May 2004 13:52:48 +0200 (CEST)
DRBD CVS committal
Author : lars
Project : drbd
Module : testing
Dir : drbd/testing/CTH
Modified Files:
Tag: rel-0_7-branch
CTH_bash.helpers CTH_bash.sh
Log Message:
autodetection whether this can be interactive
===================================================================
RCS file: /var/lib/cvs/drbd/drbd/testing/CTH/Attic/CTH_bash.helpers,v
retrieving revision 1.1.2.4
retrieving revision 1.1.2.5
diff -u -3 -r1.1.2.4 -r1.1.2.5
--- CTH_bash.helpers 28 May 2004 11:38:34 -0000 1.1.2.4
+++ CTH_bash.helpers 28 May 2004 11:52:43 -0000 1.1.2.5
@@ -1,5 +1,5 @@
#!/bin/bash -nv
-# $Id: CTH_bash.helpers,v 1.1.2.4 2004/05/28 11:38:34 lars Exp $
+# $Id: CTH_bash.helpers,v 1.1.2.5 2004/05/28 11:52:43 lars Exp $
#
# define some implicit magic
# so the definition of the DRBDs will be easier
@@ -439,6 +439,7 @@
#complete -v -X '!Node_*' Node_State Crash_Node Wait_for_boot
#complete -v -X '!Link_*' Fail_Link Heal_Link
#complete -v -X '!Disk_*' Fail_Disk Heal_Disk
+complete -v -X '![DLN][ior]*' Dump Dump_long
complete -v -X '!RS_*' Stop
complete -F _gen_comp Fail_Disk Heal_Disk Fail_Link Heal_Link
complete -F _gen_comp Crash_Node Node_State Wait_for_boot
===================================================================
RCS file: /var/lib/cvs/drbd/drbd/testing/CTH/Attic/CTH_bash.sh,v
retrieving revision 1.1.2.4
retrieving revision 1.1.2.5
diff -u -3 -r1.1.2.4 -r1.1.2.5
--- CTH_bash.sh 28 May 2004 11:38:34 -0000 1.1.2.4
+++ CTH_bash.sh 28 May 2004 11:52:43 -0000 1.1.2.5
@@ -1,5 +1,5 @@
#!/usr/bin/env - /bin/bash
-# $Id: CTH_bash.sh,v 1.1.2.4 2004/05/28 11:38:34 lars Exp $
+# $Id: CTH_bash.sh,v 1.1.2.5 2004/05/28 11:52:43 lars Exp $
# example for scripting failures
#
@@ -44,14 +44,13 @@
if [[ -e $CASE ]] ; then
echo "now run CASE=$CASE"
( source $CASE )
+elif [[ $- == *i* ]] ; then
+ set +errexit # disable this again.
+ cat <<-___
+ #
+ # now you can:
+ #
+ ___
+ Help
+ Dump_RS
fi
-
-set +errexit # disable this again.
-cat <<___
-#
-# now you can:
-#
-___
-Help
-Dump_RS
-