View Full Version : G4 directory structure questions
Mark F
February 9th, 2005, 12:36 PM
I see that the current plugins have their UI .XML files in the main Girder directory. Is that where you want all this stuff to end up? Or was this just the easy way for right now?
I would prefer a cleaner directory structure, myself. Perhaps a UI directory off of the plugins directory? Or, alternatively, a UI directory off of the main girder directory? Or even in the plugins directory with the plugin .dll file.
I have the same question about all the .dll files. Could they move to a dll directory? Or would this make installation too difficult? (changing the libpath)
What is the idea behind the LUAScript directory? Are these executed at startup and after script engine resets like the LUAEvents plugin used to do with the lua directory contents?
Sorry for all the questions. I've finally been able to look at A5 for more than 10 minutes. :)
Ron
February 9th, 2005, 12:55 PM
I see that the current plugins have their UI .XML files in the main Girder directory. Is that where you want all this stuff to end up? Or was this just the easy way for right now?
No, I simply had not gotten around to fixing the dir structure.
I would prefer a cleaner directory structure, myself. Perhaps a UI directory off of the plugins directory? Or, alternatively, a UI directory off of the main girder directory? Or even in the plugins directory with the plugin .dll file.
Let's say <girder>plugins\UI\*.xml
I have the same question about all the .dll files. Could they move to a dll directory? Or would this make installation too difficult? (changing the libpath). When does one change the libpath?
What is the reason for moving the DLLs? And won't that give us problems when libraries aren't found at runtime?
What is the idea behind the LUAScript directory? Are these executed at startup and after script engine resets like the LUAEvents plugin used to do with the lua directory contents?
The luascript directory contains scripts that are required for plugins like LuaSockets. Also this directory is included in the LUA_PATH so you can simply drop scripts in there are load them without having to specify a path.
Rob H
February 9th, 2005, 01:23 PM
The luascript directory contains scripts that are required for plugins like LuaSockets. Also this directory is included in the LUA_PATH so you can simply drop scripts in there are load them without having to specify a path.
Using require I take it?
That would be good
Ron
February 9th, 2005, 01:24 PM
yep. This should work already.
Rob H
February 9th, 2005, 01:34 PM
Cool - I'm planning to try to port LDJ to G4 by the weekend - that will prove useful.
Ron
February 9th, 2005, 01:36 PM
Does that use LuaSockets? If so wait for the next release i have upgraded to LuaSocket 2.0 beta 3. ( the current one is some earlier beta version of LuaSockets ).
Mark F
February 9th, 2005, 01:51 PM
What is the reason for moving the DLLs?
I count > 10 .dll files in the <girder> directory. It just looks messy. This is a VERY "personal taste" thing so don't worry about it.
And won't that give us problems when libraries aren't found at runtime?
If you add the extra path to the LIBPATH environment var before starting the plugins or .DLLs, putting them in a different directory won't be a problem.
Is the LUAEvents functionality of executing *.LUA in the <girder>\lua directory, or something like it, on the todo list?
Ron
February 9th, 2005, 01:54 PM
I spoke to Mike about this, but I forget what we decided. My only objection to this is code duplication.
If you add an action that runs a script on "ScriptEnable" you have the same functionality. Convince we why adding a second way of loading scripts is good :-)
edit: How can I change the LIBPATH before Girder starts? I don't want to have a .bat file going, nor doing it in the installer.
Rob H
February 9th, 2005, 02:19 PM
Does that use LuaSockets? If so wait for the next release i have upgraded to LuaSocket 2.0 beta 3. ( the current one is some earlier beta version of LuaSockets ).
I think so - it uses NetRemote Feedback.lua
Mark F
February 9th, 2005, 02:26 PM
Convenience. If I distribute a script that defines some global functionality, I don't want my user's to have to add a command to run the script file for GirderEnable and AfterScriptReset events (is that the same as ScriptEnable?). Instead, I'd like them to drop the script file into a subdirectory and have it magically work.
This was one of the reasons why LUAEvents came about in the first place. (to make NetRemote feedback work and easy to install)
On the .dll stuff, like I said, this is a personal preference thing. Don't worry about it. :)
I did some searching and the environment variable is the PATH variable, not LIBPATH as I stated before. Sorry. :(
birty
February 9th, 2005, 02:33 PM
adding the girder dll dircetory to the global path would be extremely messy and could potentially interfere with other programs
Ron
February 9th, 2005, 02:46 PM
I would agree with Birty. Globally setting the path to find girder.dll is bad news.
I'll add the Lua directory for scripts that had to loaded automatically. The other LuaEvent functionality has been implemented in gir.RegisterCB. See the manual.
Ron
February 9th, 2005, 03:15 PM
Done. Anything dropped into luascript\startup directory will be triggered on ScriptEnable
Mark F
February 9th, 2005, 03:29 PM
Okey-Dokey.
Thanks. :)
Ron
February 9th, 2005, 03:30 PM
No problem!
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.