branch: elpa/org-drill
commit 6533b732469dd4a8014e9e3ffb29625947d387ed
Author: Phillip Lord <[email protected]>
Commit: Phillip Lord <[email protected]>
Support changing small sleep on command line
---
Makefile | 8 ++++----
robot/all-card-run.sh | 2 --
robot/robot.sh | 9 ++++++++-
robot/spanish-run.sh | 2 --
4 files changed, 12 insertions(+), 9 deletions(-)
diff --git a/Makefile b/Makefile
index 4befd46231..6dfd2efe7b 100644
--- a/Makefile
+++ b/Makefile
@@ -43,15 +43,15 @@ clean-elc:
all-robot-test: basic-robot-test leitner-robot-test all-card-robot-test
spanish-robot-test
basic-robot-test: clean-elc
- $(EMACS_ENV) ./robot/basic-run.sh
+ $(EMACS_ENV) ./robot/basic-run.sh $(SMALL)
leitner-robot-test: clean-elc
- $(EMACS_ENV) ./robot/leitner-run.sh
+ $(EMACS_ENV) ./robot/leitner-run.sh $(SMALL)
all-card-robot-test: clean-elc
- $(EMACS_ENV) ./robot/all-card-run.sh
+ $(EMACS_ENV) ./robot/all-card-run.sh $(SMALL)
spanish-robot-test: clean-elc
- $(EMACS_ENV) ./robot/spanish-run.sh
+ $(EMACS_ENV) ./robot/spanish-run.sh $(SMALL)
.PHONY: test
diff --git a/robot/all-card-run.sh b/robot/all-card-run.sh
index 5f35401d27..3d70fc0dbb 100755
--- a/robot/all-card-run.sh
+++ b/robot/all-card-run.sh
@@ -7,8 +7,6 @@ source $this_dir/robot.sh
card_no=12
-small_sleep=0.1
-
function run_drill {
## Org-drill should be running at this point, so give three answers
diff --git a/robot/robot.sh b/robot/robot.sh
index c9a6169892..8b7e9a31fd 100644
--- a/robot/robot.sh
+++ b/robot/robot.sh
@@ -7,7 +7,14 @@ window_id=
## This is the small sleep between key presses. Change for debugging
## when you are not sure what is happening
-small_sleep=0.1
+echo arg is $1
+if [ -z $1 ]
+then
+ small_sleep=0.1
+else
+ small_sleep=$1
+fi
+
big_sleep=1
emacs_process_pid=
diff --git a/robot/spanish-run.sh b/robot/spanish-run.sh
index c90e31a1a9..c8cf19ad11 100755
--- a/robot/spanish-run.sh
+++ b/robot/spanish-run.sh
@@ -7,8 +7,6 @@ source $this_dir/robot.sh
card_no=15
-small_sleep=0.1
-
function run_drill {
## Org-drill should be running at this point, so give three answers