How to publish a plugin to WordPress Successfully – Step by Step Guide using Tortoise SVN

Hi Guys,

I would like to take this opportunity to put this topic on table. Now that I have released my first plugin on WordPress platform. I can share my experiences with you.

I assume that you’ve got your plugin properly tested and there are no known issues with it.

But just so that I am comfortable taking you to the next step please ask your questions below

  1. Do you have an account with wordpress?
    If your answer to above question is NO then create one from here  http://wordpress.org/support/register.php
  2. Do you have Tortoise Subversion?
    If your answer is NO. Then download the tool from here. http://tortoisesvn.net/downloads.html
  3. Do you have “Powered by” by link in your plugin and your plugin does not offer user an option to take it off?
    Very Bad. Make sure that you give your plugin user an option so that they can turn it On if they wish. Default value of your setting should be Off. In technical or HTML talk your checkbox should be Unchecked.
  4. Do you have Readme.txt file in your  plugin directory root?
    Create one. Follow the instructions from here http://wordpress.org/extend/plugins/about/readme.txt

Ok so now that we have made through the basic checklist. Next thing we would like to do is to create a Plugin Submission request

Click on the URL below and create one for your plugin. In a good time a wordpress enthusiast will get back to you normally within few hours after your plugin request submission.

Ok so here is the URL

http://wordpress.org/extend/plugins/add/

In the plugin URL field you can either point to a webpage where an admin can download your plugin from or you can put a link directly to your ZIP file. I will recommend the latter.

Now that you’ve create the request, wait till you get an approval from WordPress.

When you get an Approval you will get an email something similar to one shown below

Your plugin hosting request has been approved.

Within one hour, you will have access to your SVN repository at

http://plugins.svn.wordpress.org/your_plugin_name

with your WordPress.org/bbPress.org username and password (the same one you use on the forums).

Here’s some handy links to help you get started.

Using Subversion with the WordPress Plugins Directory
http://wordpress.org/extend/plugins/about/svn/

FAQ about the WordPress Plugins Directory
http://wordpress.org/extend/plugins/about/faq/

WordPress Plugins Directory readme.txt standard
http://wordpress.org/extend/plugins/about/readme.txt

readme.txt validator:
http://wordpress.org/extend/plugins/about/validator/

Enjoy!

Remember that you will get access to SVN in about 1 hour.

Give WordPress some time so that they can set a SVN account for you.

Now try loading the URL that you got in your email “http://plugins.svn.wordpress.org/your_plugin_name” in the browser. You will see 3 folders

  1. branches
  2. tags
  3. trunk

Ok so rather me talking in SVN language lets keep it plain simple.

Trunk is the folder where you keep your development copy, you make changes to your code and commit your changes once you are satisfied with all the changes that you’ve made.

So say your plugin file is abc.zip you should extract all files and folder under abc folder to trunk

So you end structure will look like this

trunk/pluginfile.php
trunk/readme.txt

It should not look like this

trunk/abc/pluginfile.php
trunk/abc/readme.txt

Tags is the folder where you keep your plugin versions.

So version 1.0 of your plugin will be under tags folder like this

/tags/1.0/pluginfile.php
/tags/1.0/readme.txt

We will see more of it later in this article.

Lets move on for now

Now that we have Tortoise SVN Goto the folder you would like to checkout your plugin to and Right Click  to get Tortoise SVN options as shown below

Wodpress plugin checkout

check out  with Tortoise SVN as shown below (paste the URL that you got in your email under URL to repo field below)

Choose your Checkout directory that is accessible to you.

Wordpress Plugin Submission

 

Now a directory with your plugin name will be created wherever you choose to CheckOut.

Now once you click Ok a new directory will be created. You now should put all your files All PHP’s, Images, readme.txt, CSS and Javascript files under trunk folder that get created when you checked out your repo.

Example is shown below

Plugin trunk view

 

I hope that you’ve created your readme.txt file If not here is a sample from my plugin

=== JC Coupon ===
Contributors: Jaspreet Chahal
Donate link:http://jaspreetchahal.org/wordpress-jc-coupon-plugin-lite/
Tags: JC Coupon, coupon, coupons, affiliate, links, import coupons, promotional codes
Requires at least: 3.3.0
Tested up to: 3.3.2
License: GPLv2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Stable tag: 1.0

== Description ==

JC Coupon is a WordPress Coupon Plugin which Allows You To Add Coupons on any post or page. You can set expiry date or custom text for expiry. Coupons when pass their expiry date will not show up. You can use shortcodes on pages and posts

When you set coupon with no expiry date they will appear indefinetly

This is must have affiliate tool where your URLs are masked and a click on your coupon will mean a hit to your your affiliate link.

visit http://jaspreetchahal.org/wordpress-jc-coupon-plugin-lite/ for help.

== Installation ==

1. Upload JCCoupon directory to the /wp-content/plugins/ directory
2. Activate the plugin through the ‘Plugins’ menu in WordPress
3. Use the JCCoupon Options on left to make create and manage coupons.

== Frequently Asked Questions ==

How do I contact you?

website: http://www.jaspreetchahal.org/contact-me/

Is this plugin free?

Yes. but there is a pro version available too with loads of other options. Check it here
http://jaspreetchahal.org/wordpress-coupon-plugin-jc-coupon-revealer-pro/
View the screenshots tab here on wordpress

== Screenshots ==

1. List yoru screenshots file name here. Check out the link I provided above on how you can format this section

== Changelog ==
= 1.0 =
Initial Release

I’ve bolded the “Stable tag” setting because this is what we will looking at next.

Under my plugin I’ve put Stable tag as 1.0 thus I will now create a folder called 1.0 under Tags folder that was created as a result of checkout as shown below

Wordpress Plugin Tags folder SVN

The Tags folder will keep your Plugin stable release that will be downloaded by many. So you will have to make sure that the code that you put in there is working and is not broken.

Ok so now that we have created 1.0 (You can create your own version directory, make sure that you update your Stable tag value to whatever you used to create the directory)

Tags are used to notify your plugin users that a new version is available. This is WP way of managing versions for your plugin. Major changes should be released under new Tag (That’s what I recommend). If your updated your screenshot etc they are more of WP related and I deem them as minor changes and they should be committed under same tag.

Copy Paste all your existing Plugin files to your new folder under Tags folder as shown below

Wordpress SVN tags folder paste

 

Now when you are done with this. Its time to Commit your stuff to your repo. Right Click on the folder that you initially checked in your plugin to and click Commit (example shown below)

Wordpress Plugin Commit

Advertisement

 

Ok So now you’ve committed your stuff in. That’s it. Your new Plugin is now available for download from Worpress Plugins page.

Lets add Some Screenshots

Screentshot file name must be in format

screenshot-1.png
screenshot-2.png
screenshot-3.png

You can paste your screenshots under your trunk folder and they will be automatically picked by wordpress when you check them in (Commit)

Make sure that you add reference to your screenshots in readme.txt file to give them titles

Validating readme.txt

Goto http://wordpress.org/extend/plugins/about/validator/

to validate your readme.txt file.  This validator will give you more accurate info on if you have done something wrong in your readme.txt

Now next up is

How we can have header Picture for our plugin.

Lets do that

At the same level as trunk and tags folder create a folder called assets

Now create a file with exactly these dimensions

Width: 772px
Height: 250px

Save this file as  “banner-772×250.png” or “banner-772×250.jpg” under assets folder as shown below

Wordpress Plugin Header Image

 

Commit your changes.

Ta! da! Refresh your plugin page in wordpress in about a minute. Your header image will start to appear there.

Please note: GIF files are not allowed. Keep your files extension to .png or jpg.

 

I hope that this helps.

Your positive contribution in comments will be highly appreciated.

Cheers,

 

Advertisement

 

Comments

  1. dien dan rao vat says

    Truly no matter if someone doesn’t know tthen its uup to other visitors
    that they will assist, so here itt takes place.

  2. Tony Hill says

    love the article I bookmarked

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.