lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On Thu, Nov 6, 2008 at 10:51 PM, Yogesh Gaur <yogeshgaur.83@gmail.com> wrote:
> This is my first mail to the Lua mailing list.
>
> I want to know that is there any way through which we can call the one Lua
> script inside the other script. Actually, my requirement is that I have to
> call one general script which would set my variables, preparing the system
> for me and then through other scripts I am performing different different
> operations on the basis of the variables set by the first script.

You'll find reading through the manual really useful, I keep it open
all the time!

See:

http://www.lua.org/manual/5.1/manual.html#pdf-dofile

Also, you can do
   require"setup"
to do setup.lua from somewhere in the lua's package.path.

Cheers,
Sam