Skip to content


Switch branches/tags

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

Gem Version Dependency Status Build Status Code Climate Test Coverage


Welcome to GenericGem! The purpose of this gem is to streamline the process of creating a gem with Bundler.

What's the point?

I HATE having to jump through hoops just to take care of the generic details that are necessary for all or most Ruby gems. Every time I have created a Ruby gem, there were numerous details that I had to remember to do. The generic aspects of a gem are fully automated to minimize the drudgery so that you have more time available to work on the capabilities that make your Ruby gem unique.

Prerequisites for Understanding GenericGem

You should be familiar with the process of building a Ruby gem. Some good resources are:

How does GenericGem work?

GenericGem uses the bundle command to begin the process of creating a gem. Additionally, it adds a number of enhancements needed by all or most Ruby gems. These changes are:

  • The Code of Conduct and MIT license are automatically included. (It's easier to remove them than to remember to add them.)
  • Your name is automatically filled in the file LICENSE.txt and in the gemspec file.
  • The gem description in the gemspec file is "GENERIC DESCRIPTION" to enable the "rake install" command.
  • The gem summary in the gemspec file is "GENERIC SUMMARY" to enable the "rake install" command.
  • Your email address is automatically provided in the gemspec file.
  • RSpec testing is automatically included and installed. Your gem will pass the initial meaningless tests.
  • The version number is set to 0.0.0.
  • The bin/console and bin/setup script files are made executable.
  • A working Rakefile is provided.
  • The script is added to the gem's root directory. This is the 1-step test procedure that executes the bin/setup script (which includes the "bundle install" command) AND the command "rake". Just enter the command "sh" command to start the process. When you clone your gem's source code onto a machine with a fresh Ruby on Rails installation, running the script should confirm that all of the details needed to make your gem work are complete.
  • The .gitignore file includes .DS_Store and the directories tmp and tmp*.
  • Instructions on using the and scripts are included in the file.


Add this line to your application's Gemfile:

gem 'generic_gem'

And then execute:

$ bundle

Or install it yourself as:

$ gem install generic_gem


Just enter the command "generic_gem". When prompted, provide the name of your new gem, your name, and your email address. Your new gem will be automatically created AND tested. The initial meaningless tests will pass.


Testing this gem

After cloning this source code, cd your way into this directory and enter the command sh Note that this script also runs the and scripts.

Testing this gem's source code

Enter the command sh to test the quality of the source code.

Running this gem in irb

Enter the command sh

Installing this gem

Enter the command sh


  1. Fork it ([my-github-username]/generic_gem/fork )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request


No description, website, or topics provided.



Code of conduct





No releases published


No packages published