Skip to content

Commit

Permalink
bash-lua-helper: added more info to README.md and lua example scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
DarkCaster committed Dec 2, 2016
1 parent 6c161da commit 0bad146
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 1 deletion.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,5 @@ You can also put all verification logic to a separate script, that will be execu

You need an installed lua interpreter in your system. Tested with Lua v5.2.2

TODO: usage description and examples
TODO: usage description and examples. for now see example.sh source for usage example

3 changes: 3 additions & 0 deletions example.cfg.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
-- load this config script and execute with bash helper (or loader.lua)

loader.log("message from main config script")

config =
{
value="some text there",
Expand Down
2 changes: 2 additions & 0 deletions example.post.lua
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
loader.log("message from optional post script")

assert(tonumber(config.sub.number1) ~= nil)
assert(tonumber(config.sub.number2) ~= nil)
--assert(tonumber(config.sub.string) ~= nil)
Expand Down
1 change: 1 addition & 0 deletions example.pre.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
loader.log("message from optional pre script")

0 comments on commit 0bad146

Please sign in to comment.