This article describes a simple way how to update your plugin by using the TortoiseSVN. TortoiseSVN is a powerful tool for subversion control, in your case used for the management of your plugin stored in the WordPress repository.
The main idea of SVN is to monitor changes being made by different users on the same files, in order to avoid uncontrolled overwriting of someone else’s work.
To get started, get your copy of TortoiseSVN and install it at your Windows computer. Following steps will guide you through the whole process of downloading, updating and committing changes into your WordPress plugin.
Step 1 – The Initial Check-Out
- Create a directory where you wish to store your plugin.
- Right click on this folder and select SVN Checkout…, a window similar to the one below will appear.
- Type in the URL of the repository, for wordpress plugin it should be
http://svn.wp-plugins.org/your-plugin-name
Replace your-plugin-name with the name of your plugin, for example
http://svn.wp-plugins.org/foliopress-wysiwyg
- The Checkout is being performed, all files that are being downloaded are listed.
- You may notice that the icon of the directory changed, and a green tick appeared in the lower left corner. Looking into the plugin directory you see that every other directory and file icon contains this green tick as well.
TortoiseSVN Checkout
Files after checkout
Step 2 – Updating the files
- Directory your-plugin-name/trunk contains the actual version of your plugin.
- Edit the files in the text editor of your choice. You might want to look at Readme Standard on WordPress.com or Readme Validator on WordPress.com to do the changes correctly.
Step 3 – Committing changes
- After editing a file you certainly noticed that it’s icon has changed, a red exclamation mark appeared. This means the file has been changed and it will need to be committed.
- You can commit either the single file or the whole directory. Again right click on the file/directory and select SVN commit
- A Commit window will pop up, where you can type a comment about the changed you have made. It’s good habit to always type a short comment so everybody quickly understands what exactly has been changed.
- You will be asked about your username/password.
File readme.txt has been changed
Step 4 – Further Changes
- Once you have your local copy, you are free to do any other changes here, skipping the Step 1.
- However, it’s a good practice to always update the whole repository before you start changing something – right click on the plugin directory and select SVN Update. This way you are sure you are editing the latest version of the plugin.
- If any type of conflict appears, TortoiseSVN shows a list of files that were not updated/committed because there was some kind of conflict. It let’s you to open both files – your local copy and the one from the server, you can check for conflicts which will be highlighted and you decide which changes will be skipped and which left.
If you are a Mac user, please follow the guidelines for Updating the WordPress plugin from Mac.
Leave a Reply