http://ruby-gem-downloads-badge.herokuapp.com/ - gem downloads shields

Inline docs Code Climate Analytics

Clean and simple gem download badge, courtesy of shields.io, that displays the downloads number of your gem. By default will display the downloads count of the latest version of the gem provided.

Currently this service supports only SVG, PNG, JPG (or JPEG) and JSON format

The JSON format though will not display a badge but the data received from rubygems.org in JSON format

Use

In your README.md, just add an image with the base URL (http://ruby-gem-downloads-badge.herokuapp.com/) followed by the gem name and the version, for example :

You will then get a nice and pretty SVG with the downloads count of the gem provided:

  ![](http://ruby-gem-downloads-badge.herokuapp.com/rails)

Or you can use any extension you like like this (e.g. PNG, JSON):

  ![](http://ruby-gem-downloads-badge.herokuapp.com/rails?extension=png)

You can also specify the version of the gem, for example:

  ![](http://ruby-gem-downloads-badge.herokuapp.com/rails/4.1.0)

You can also specify to display the total downloads count like this:

  ![](http://ruby-gem-downloads-badge.herokuapp.com/rails?type=total)

You can also specify to display the total downloads count for a version like this:

  ![](http://ruby-gem-downloads-badge.herokuapp.com/rails/4.1.0?type=total)

You can also customize the message displayed when using type=total params by using this:

  ![](http://ruby-gem-downloads-badge.herokuapp.com/rails?type=total&total_label=total-awesome)

If you want the downloads count to use metrics,, you can add &metric=true at the end of the url.

![](http://ruby-gem-downloads-badge.herokuapp.com/rails?metric=true)

That's it!

Further Customization

If you want to change the color of your badge, just append &color=COLOR_NAME to the image URL. By default, the badge is blue.

Available colors are (gem is rails):

Color Badge
brightgreen
green
yellowgreen
yellow
orange
red
lightgray
blue
ff69b4

If you want to style of the badge just append &style=STYLE_NAME.to the image URL. By default, the badge is flat

Available styles are:

Style Name Badge
flat
plastic
flat-square
social

For social badges you can also use links for both sides of the badge like this:

![](http://ruby-gem-downloads-badge.herokuapp.com/rails?style=social&link=http://google.com&link=http://yahoo.com)

If you want something else written on the badge you can use:

![](http://ruby-gem-downloads-badge.herokuapp.com/rails?label=something-else)

You can change the logo width by using this:

![](http://ruby-gem-downloads-badge.herokuapp.com/rails?logoWidth=80)

If you specify a version that is not valid like this, you will see a invalid image:

![](http://ruby-gem-downloads-badge.herokuapp.com/rails/4.1.dsad)


This repository was created by bogdanRada - but is completely built off of shields.io - go check them out! Having a problem? Open an issue.