summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2010-11-24 20:27:08 +0000
committerChristian Pointner <equinox@spreadspace.org>2010-11-24 20:27:08 +0000
commit908571214ee1b8aeb73c629203d80755d6192474 (patch)
tree6413229e8b2cbae9d7e73d49989288aa1b7c0a48 /examples
parenttab vs space (diff)
debugged dispatch table
added basic mode added runtype to modules git-svn-id: https://svn.spreadspace.org/gcsd/trunk@61 ac14a137-c7f1-4531-abe0-07747231d213
Diffstat (limited to 'examples')
-rw-r--r--examples/basic_mode.lua6
-rw-r--r--examples/simple_dispatcher.lua6
2 files changed, 6 insertions, 6 deletions
diff --git a/examples/basic_mode.lua b/examples/basic_mode.lua
new file mode 100644
index 0000000..04c16df
--- /dev/null
+++ b/examples/basic_mode.lua
@@ -0,0 +1,6 @@
+return {
+ ["%w+%s*\n"] = function(match)
+ command_queue:enqueue(string.match(match , "(%w+)%s*"))
+ end,
+ [".*\n"] = function(match) end
+}
diff --git a/examples/simple_dispatcher.lua b/examples/simple_dispatcher.lua
deleted file mode 100644
index 4c935fe..0000000
--- a/examples/simple_dispatcher.lua
+++ /dev/null
@@ -1,6 +0,0 @@
-return {
- ["%w+%s*\n"] = function(match)
- local cmd = string.match("(%w+)%s*", match)
- command_queue:enqueue_command(cmd)
- end
-}