| Andreas Rozek |
|
Lua_00 - a first simple Lua Script"Lua_00" demonstrates the invocation of Lua scripts and tests the proper handing over of any given command line arguments. The program itself is extremely simple and therefore does not require any further explanation. Upon an invocation of the form lua Lua_00.lua one_word "multiple words" "multiple words with \" in between" the program produces the following output: Lua_00 - lists the given command line arguments
got 4 arguments:
1) "Lua_00.lua"
2) "one_word"
3) "multiple words"
4) "multiple words with " in between"
If invoked without any command line parameters lua Lua_00.lua it simply shows: Lua_00 - lists the given command line arguments
got one argument:
1) "Lua_00.lua"
Source CodeThe source code of this example is available for download:
References
|
| http://www.Andreas-Rozek.de/Lua/Acquainting/Lua_00_en.html | (last Modification: 15.04.2002) |