Skip to content
Derek Jones edited this page Jul 5, 2012 · 4 revisions

Category:Contributions::Libraries::GitHub Updater Category:Libraries::GitHub Updater Category:Library::GitHub Updater

If you have a CodeIgniter application or just a remote instance that you need to keep updated, I made a library to make that easier.

Here is the GitHub repo:

https://github.com/jimdoescode/CodeIgniter-GitHub-Updater

It works with GitHub and determines if the current file version locally is the same as the version on GitHub. If not then it will update your local files to the version on GitHub. There are two methods to the library.

$this->github_updater->has_update();
$this->github_updater->update();

The first does a check to see if your local files are the same as what is available on GitHub. The second will actually pull down the files from GitHub and perform an update if your local version is not the same. One nice thing about this library is that it isn't dependent on you having git on your local server. You should be able to run it on any *nix server.

Please make sure that you perform a backup prior to running the update method. It can be destructive if used improperly.

For more information check out my blog

http://jimdoescode.blogspot.com/2012/02/keep-your-ci-instances-up-to-date-with.html

Clone this wiki locally