From 84e0bdb95032e860a041dbb03702ffaf7925f1d4 Mon Sep 17 00:00:00 2001 From: sammy <38820196+TorchedSammy@users.noreply.github.com> Date: Sun, 21 Mar 2021 14:06:12 -0400 Subject: [PATCH] Created Commander (markdown) --- Commander.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 Commander.md diff --git a/Commander.md b/Commander.md new file mode 100644 index 0000000..62246bd --- /dev/null +++ b/Commander.md @@ -0,0 +1,16 @@ +Commander is Hilbish's custom command library, a way to write commands with the shell in Lua. +To require: +```lua +local commander = require 'commander' +``` + +# Functions +### Commander.register(cmdname, cmdfunction) +Registers a new command named `cmdname`, which executes `cmdfunction` when ran. + +#### Example +```lua +commander.register("hello", function () + print(ansikit.text "{blue}Hello world!{reset}") +end) +``` \ No newline at end of file