Git Updater self-updates
Simple plugin to sync wordpress plugins from Git Repos
by Rune Brimer · github.com/chit112/wordpress-git-updater · website
Install
No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:
wp plugin install https://github.com/chit112/wordpress-git-updater/archive/refs/heads/main.zipShips its own WordPress updater (built-in updater), so new versions show up under Dashboard → Updates.
Git Updater for WordPress
Git Updater allows you to easily install and update WordPress plugins directly from GitHub repositories, supporting both public and private repositories.
Features
- Private Repository Support: Authenticate using a GitHub Personal Access Token (PAT).
- Branch Selection: Install plugins from any specific branch (defaults to
main). - Auto-Updates: Integrates with WordPress's native update system.
- Robust Installation: Handles filesystem permissions automatically with native PHP fallbacks.
- Verbose Logging: Debug installation issues with a built-in log viewer.
Installation
- Download the
git-updaterplugin zip: Download Latest Zip - Go to your WordPress Dashboard > Plugins > Add New > Upload Plugin.
- Upload and activate the plugin.
Configuration
1. Generate a GitHub Token
To access private repositories (and to increase API limits for public ones), you need a GitHub Personal Access Token.
- Go to GitHub Settings > Developer Settings > Personal Access Tokens > Tokens (classic).
- Click Generate new token (classic).
- Give it a Note (e.g., "WordPress Git Updater").
- Select the
reposcope (for private repositories) orpublic_repo(for public only). - Click Generate token.
- Copy the token immediately.
2. Configure the Plugin
- In your WordPress Dashboard, go to Settings > Git Updater.
- Paste your GitHub Token in the "GitHub Access Token" field.
- Click Save Settings.
Usage
Installing Plugins
- Go to Settings > Git Updater > Install New Plugin.
- Repository: Enter the full URL (e.g.,
https://github.com/Let-s-Roll/wordpress-admin-ui) orowner/repo. - Branch: (Optional) Leave empty for
mainor specify a branch. - Target Slug: The folder name you want for the plugin (e.g.,
lets-roll-admin). - Click Install Plugin.
- The plugin will be installed and automatically added to the monitored list.
Managing Monitored Plugins
The Installed & Monitored Plugins list is read-only to ensure safety and integrity.
- Monitoring: All installed plugins in this list are automatically checked for updates.
- Changing Branch: If you need to switch branches (e.g., test
develop), Remove the plugin from the list and Re-install it with the desired branch. - Removing: Click Remove to stop monitoring a plugin (this does not delete the plugin files).
Updating Plugins
Once a repository is added to the "Monitored Repositories" list:
- The plugin will check GitHub for updates every 12 hours (standard WordPress interval).
- If the
Versionheader in the remotemainbranch is higher than your installed version, an update will appear in Dashboard > Updates. - Click update just like a normal plugin!
Troubleshooting
- Installation Failed?: Check the "Installation Logs" text area at the bottom of the Settings page.
- GitHub Token: Ensure your token has the correct
repopermissions. - File Permissions: The plugin attempts multiple methods (WP Filesystem, Native PHP) to handle file moves. If it fails, ensure your
wp-content/pluginsfolder is writable by the web server.
Author
Rune Brimer https://github.com/chit112/wordpress-git-updater