I often extract code I use into libraries so I can reuse them. Creating a new library is a bit overwhelming since there is plenty of boilerplate code to write, specially if you want to integrate your library with style checkers, continuous integration services and things of the kind.

So today, before creating my next lib I decided to create a template for my libraries. I wanted something as simple and elegant as bundle gem {gemname}.

Turns out composer allows you to easily create project by using templates (skeletons). I found this article that gave me some insights on how to build my own template.

It contains badges for Travis CI, Coveralls, Code climate, Scrutinizer, Style CI, Packagist, Gemnasium and more. Of course, you need to manually integrate the services to your github repo.

It is hosted here and this is how you use it:

composer create-project -sdev mjacobus/library-skeleton /path/to/project

After that you can run:

cd /path/to/project
./bin/configure_project.sh

It will asked for your library information, and replace the placeholders in the templates. After that you should be ready to start working in the implementation of your lib.