Updating your wordpress plugin can be confusing if you’re doing it the first time. It’s easy but can be confusing if you don’t know the right steps.
So here is the step by step process to do it right and quickly without any confusion:
- Make the changes in the code in your plugin code.
- Test the plugin on a test environment before pushing to your Github repository. Assuming you have one.
- Once tested, edit readme.txt. Update change log, version and stable tag.
- Once readme.txt has been updated, update version in your plugin’s main file for example: plugin-name.php.
- Once done push the changes to your git repository.
- Create a release in github. So if version number you are upgrading to is 1.0.1 then create a release with the title “Version 1.0.1”, update the changes in the description, and save it.
- Now we are good with the changes, let’s clone the wordpress plugin svn repo on your system. Repository url will be like this: https://plugins.svn.wordpress.org/your-plugin-name. You can use any SVN client for the same.
- In your SVN repository, go to tags folder, and create a new folder with the name same as version number. So in our case it will be 1.0.1 given version number we are upgrading to is 1.0.1.
- Put the latest code with all the change we made in this newly created folder.
- Now go to trunk folder in the root folder of your SVN repository, delete everything from there and put the latest code.
- Once done, commit the repository back to your WordPress SVN repository.
- Now go to WordPress plugin page and check if version is up and test it on your blog.
How easy was that.