NetLoadModule2

Revenge of the Common Module Directory
version 2.02 by RabidCow


NetLoadModule allows you to load modules that may not necessarily be installed. If the module is not installed, it can be automatically downloaded and installed before being loaded.

Settings THEME AUTHORS should worry about.

Settings USERS should worry about.





Operation



When NetLoadModule first starts, it loads the list of *NetLoadModule files and checks if all of the modules exist. If they do, they are then all loaded, in order, and LiteStep continues loading.

If one or more of the modules does not exist, NetLoadModule will display a dialog box containing a list of them. Any descriptions given will be displayed next to the modules. The user can select the location of modules that exist, but not where NetLoadModule expected through a context menu (this is slightly hidden because it is an advanced feature) and then has a choice as to whether or not to download and install these modules.

NetLoadModule then downloads and installs the modules in order, first looking for the archive in the NetLoadModuleZipPath, then the primary site list with the module, then the *NetLoadModuleSite lines.

If a module archive is found that contains more than one dll file, the user is presented a list of the dlls and asked which is the module to load. There is a button to open the documentation to make this decision easier. NetLoadModule cannot decide automatically because there is no easy way to guess which file is the module, and which other dll files are required.

If any modules fail to install, the list is presented to the user again, otherwise NetLoadModule loads all its modules in order and LiteStep continues to load as normal.









Theme Specific



*NetLoadModule <module name> [<optional URL>] [<description>]

This specifies a module to be loaded, instead of using a LoadModule line for that module. The module name should include the name and version number, but does not need to include a path or extension. This name uniquely identifies this version of this module and is used to determine if the correct version is installed, and where to get it if it is not.

If the optional URL is given, this is tried before any *NetLoadModuleSite sites, in this case nothing additional is appended, this is the complete URL to the archive.

The description may be displayed to the user to describe what this module is used for, it doesn't affect how it is loaded in any way.

The URL may be included in quotes, use "" if you want to leave it out and add a description. The description should not be in quotes unless you want them to show up.

If you are loading RabidVWM v1.0 beta 3:

LoadModule $ModuleDir$rabidvwm.dll
You can load it with NetLoadModule:
*NetLoadModule rabidvwm-1.0-beta_3
or
*NetLoadModule rabidvwm-1.0-beta_3 "" the box with stuff that you click on

*NetLoadModuleSite <URL> [<suffix>]

This specifies a site to download any missing modules from. The module name will be appended to the end of the URL and the suffix will then be appended to the end of that. If no suffix is given, ".zip" is used.

At least one download site should be specified by the theme itself, additional sites can be specified by the user. (In the case of a distro, one download site should be specified by the distro rather than each theme.)

ShellFront's module archive would be:

*NetLoadModuleSite "http://www.shellfront.org/modules/"
or, if you wanted to include the suffix:
*NetLoadModuleSite "http://www.shellfront.org/modules/" ".zip"
although that's not necessary in this case.

NetLoadModuleTestMessage

This tells NetLoadModule to always display the download module dialog, even if all the modules can be found. All *NetLoadModules will be listed, not just the modules that can't be found.









User Specific



*NetLoadModuleSite <URL> [<suffix>]

This specifies a site to download any missing modules from. The module name will be appended to the end of the URL and the suffix will then be appended to the end of that. If no suffix is given, ".zip" is used.

At least one download site should be specified by the theme itself, additional sites can be specified by the user. (In the case of a distro, one download site should be specified by the distro rather than each theme.)

ShellFront's module archive would be:

*NetLoadModuleSite "http://www.shellfront.org/modules/"
or, if you wanted to include the suffix:
*NetLoadModuleSite "http://www.shellfront.org/modules/" ".zip"
although that's not necessary in this case.

NetLoadModulePath <path>

This sets the path where NetLoadModule looks for modules, and where it will install them to. This defaults to $LiteStepDir$modules\. This directory must already exist.

If a module has an alias, NetLoadModule does not look for it in the module path, only at the location specified in the alias file.

NetLoadModuleDocPath <path>

This sets the path where NetLoadModule will install any documentation included with modules that it installs. The default is $LiteStepDir$modules\docs\. If the folder does not exist, it will be created.

NetLoadModuleZipPath <path>

This sets the path where NetLoadModule saves the zip files that it downloads. The default is to not save them. NetLoadModule will also look for archives here before downloading them, so if you just delete the module, it will be installed from the local copy. If the folder does not exist, it will be created.

NetLoadModuleAliasFile <file>

This specifies the file where NetLoadModule loads/saves paths for modules that are not simply in the NetLoadModulePath. This file is formatted like an ini file, entries are of the form module-name=path\to.dll, which can include litestep $variables$, under a [NetLoadModule] section. The default is $LiteStepDir$modules.ini.

Example entry added by NetLoadModule when installing ckHotspots 2.2:

ckhotspots-2.2=$litestepdir$modules\ckhotspots-2.2\ckHotspots.dll









History



v2.02 2002-05-08
v2.01 2002-04-27
v2.0 2002-04-25
Initial release of version 2 code.