The gist of SVN for updating plugins in the WordPress plugin directory

Every time when I update my plugin to the WordPress plugin directory, I forget how to use SVN 🙁 This is why I am writing this post which is actually my to-do list for updating plugins through SVN. I hope it might help someone out there who is like me.

I assume you already have the SVN repo in your local system. Let’s make sure it’s updated as per the WP plugin directory.

$ svn up

Now do your changes. Actually, in my case, I keep my SVN repo in a separate place from my development environment. So I need to copy and paste my whole plugin files into the trunk folder. Now check the status with the following,

$ svn stat

It will show you the list of files you change for update with an M before the file name.

Now is a good time to add a Tag for your new version. For this do the following,

$ svn cp trunk tags/1.0.3

Replace 1.0.3 with your new version number and make sure you update this version number in your Stable tag field in your readme.txt file.

Now let’s push our changes into the central repository, which will reflect the changes in WordPress plugin directory with the following command,

svn ci -m "My update version 1.0.3" --username YourUserName --password YourPassword

I am using username and password with the commit command because, from my current machine, I manage two different accounts. One can commit the username and password part if s/he manages a single account.

I am publishing the gist of updating the plugin before adding it because I am facing this right now. I will publish another gist for adding when I publish a new plugin later. 🙂

(Visited 65 times, 1 visits today)

Leave a comment

Your email address will not be published. Required fields are marked *