diff options
author | Solderpunk <solderpunk@sdf.org> | 2018-12-07 20:32:55 +0000 |
---|---|---|
committer | Solderpunk <solderpunk@sdf.org> | 2018-12-07 20:32:55 +0000 |
commit | ca90a682b686c55a1d359a39f41b86ddacaee982 (patch) | |
tree | 6213f7c8280f7bb2e5a289d949b31ba50a697c06 /telem.lua | |
parent | Add new board support. (diff) |
Add support for top-level reply command (outside of ).
Diffstat (limited to 'telem.lua')
-rwxr-xr-x | telem.lua | 16 |
1 files changed, 15 insertions, 1 deletions
@@ -286,6 +286,20 @@ function do_quit() print("Goodbye!") end +function do_reply() + if current_board == "" then + print("Not at any board!") + return + end + print("Reply to which thread?") + local thread_id = string.upper(io.read()) + thread = current_thread_index[tonumber(thread_id)] + current_thread_subject = thread.subject + current_thread_posts = get_posts(thread) + current_thread_index = #current_thread_posts + do_type_reply() +end + function do_rules() cat_file("/var/bbs/docs/rules") end @@ -327,7 +341,7 @@ dispatch["s"] = do_unimplemented dispatch["="] = do_unimplemented dispatch["M"] = do_unimplemented dispatch["n"] = do_new -dispatch["r"] = do_unimplemented +dispatch["r"] = do_reply dispatch["b"] = do_board dispatch["c"] = do_unimplemented |