Allows developers to automatically update their plugins and files. Updates will be checked on server startup and then once every 24 hours. All updates will be logged to Updater.log in your SourceMod log directory.

/**
* Adds your plugin to the updater. The URL will be updated if
* your plugin was previously added.
*
* @param url URL to your plugin's update file.
* @noreturn
*/
native Updater_AddPlugin(const String:url[]);
/**
* Removes your plugin from the updater. This does not need to
* be called during OnPluginEnd.
*
* @noreturn
*/
native Updater_RemovePlugin();
/**
* Forces your plugin to be checked for updates. The behaviour
* of the update is dependant on the server's configuration.
*
* @return True if an update was triggered. False otherwise.
* @error Plugin not found in updater.
*/
native bool:Updater_ForceUpdate();
/**
* Called when your plugin is about to be checked for updates.
*
* @return Plugin_Handled to prevent checking, Plugin_Continue to allow it.
*/
forward Action:Updater_OnPluginChecking();
/**
* Called when your plugin is about to begin downloading an available update.
*
* @return Plugin_Handled to prevent downloading, Plugin_Continue to allow it.
*/
forward Action:Updater_OnPluginDownloading();
/**
* Called when your plugin's update files have been fully downloaded
* and are about to write to their proper location. This should be used
* to free read-only resources that require write access for your update.
*
* @note OnPluginUpdated will be called later during the same frame.
*
* @noreturn
*/
forward Updater_OnPluginUpdating();
/**
* Called when your plugin's update has been completed. It is safe
* to reload your plugin at this time.
*
* @noreturn
*/
forward Updater_OnPluginUpdated();
/**
* @brief Reloads a plugin.
*
* @param plugin Plugin Handle (INVALID_HANDLE uses the calling plugin).
* @noreturn
*/stock ReloadPlugin(Handle:plugin=INVALID_HANDLE);

When testing an update with your plugin, I recommend that you test it against a debug version of Updater. It will log detailed download information to Updater_Debug.log in case you accidentally used malformed URLs or paths.

Updater 1.1.0
- Added support for downloading updates using the SteamTools extension.
- Added a command to force all plugins to be checked for updates: sm_updater_check
- Improved logging on unsuccessful updates.

Quote:

Updater 1.0.2
- Added a log message when a plugin was successfully updated.
- Added a log message when Updater restarts itself after being updated.

I made this because that plugin had bugs piling up and it wasn't being maintained. I originally made this for SMAC early in the year, but decided to release it as a separate plugin so that anyone could use it in other projects, including my own.

I incorporated this quick list of ideas to start:

Quote:

Originally Posted by GoD-Tony

Bug fixes.

Path_SM support instead of having to hardcode the SourceMod folder (none of my servers used the original name).

KeyValue files instead of XML.

More features for developers, and less confusing for users.

The auto-updating plugin should update itself, so that other plugins can always rely on the latest features/fixes.

In addition, XML wasn't very pawn friendly, and there was a bug that scattered files if the URL or local path was too long. This plugin also lets the user to choose which extension they want to use (some had crashing issues with Sockets).