How to write my own gem
Creating gems and plugins for Rails 3
shyam mohan commented
there is very good example: http://guides.rubygems.org/make-your-own-gem/
Ryan Bigg commented
I've already written a guide that covers how to write your own gem here: https://github.com/radar/guides/blob/master/gem-development.md.
What else would you like to see in one?