Licence
=======
The module is free to distribute for all. The module can be distributed on its own with or without the documentation for version 0.01. Source code not available for version 0.01. Graeme Shrimpton.


ModNewest
=========
Loads in the newest known version of a module instead of the requested file. It logs as you work and may require a reboot before you see good results.

You can load this by double-clicking the ModNewest file in the filer, however it is recommended that this is added to your Configure -> Boot -> Run list to ensure this runs at every startup, after the OS and Desktop has loaded.


Why Would We Need This?
=======================
Some modules once loaded cannot be updated to a newer version. This is because the have an 'open state' that cannot be passed onto a newer version.


Why Does It Not Work First Time?
================================
ModNewest only stores module data as they are seen by running an application that uses the RmLoad command.


An Example of Why?
==================
I understand that the Socket or SocketWatch module cannot be removed once running.

Some applications have version 0.05 and others have 0.06 within the application itself. Running an application with ModNewest running and 0.05 in the application will load 0.05. Now, running an application with 0.06 will fail, however version 0.06 has been logged by ModNewest. Next time you reboot, both applications should run and both should load 0.06. If you encounter an application that cannot use the latest version, please have a look at the configuration section to exclude that module from ModNewest.


Where Did the Module Load From?
===============================
A system variable call ModNewest$@<ModuleName> will show the location, version number and date of the actual loaded module. Enter *Show ModNewest$@* to show all. This will not be set if the RmLoad command finds that the newest version it can find is already running.


How Does This Work?
===================
This intercepts the RmLoad command which loads a module. When a module is requested to be loaded, ModNewest will look at the file and get details from within it. It will then have a look it in your system directory (commonly known directories only) and your choices directory (*) to see if it can find an even newer version.

There is a check to see if you are already running the newest known version. If your version is newer than any found in files, ModNewer will do nothing.

If it finds a newer version in any of the locations it checks, it will load this instead. A copy of the newest version of the module will also be stored in your choices directory. The next time you load the same module (of a possibly different version) your choices directory will also be checked, ensuring that you will get the newest version of the module ever seen. It is safe to delete modules from your choices directory.

A newer version is defined as one with a newer version number defined in the help string. If multiple modules are found with the same version number NodNewer will choose the one with the newest date.

When the RmLoad command points to a non-valid module or a file that does not exist, an error will occur, the same as an invalid RmLoad command. ModNewer will not try to look in System or other places if the file in the command does not exist or cannot be opened.


Configuration
=============
Module copies are stored in your choices directory in ModNewest. You can store a text file with module names to ignore. This file must be called 'Ignore' and contains modules titles, one per line that you wish to ignore. Please note that these are module titles, not filenames: SharedCLibrary and not CLib. Some modules are ignored by default.


Stopping ModNewest
==================
Enter the command '*Rmkill NodNewest' and it will remove the module.


Avoiding ModNewest Loading the Latest
=====================================
You can avoid the all ModNewest checks by using *%RmLoad instead of *RmLoad

Currently, you can also double-click a module in the filer and the module you double-clicked on will be loaded. This may change if RmRun is fixed.


Issues
======
Amulator has different versions for different processors. These modules are ignored by ModNewest because you want the one that your processor supports, not the newest version number.

RmLoad works. RmRun is currently ignored as this causes issues.

There are two commands provided by ModNewest: RmLoadNewest and RmRunNewest. You should not use these directly. There are issues with RmRunNewest at the moment, please do not use this at all  until a version that supports it can be released.