DEV Community

Cover image for Adding badges to your open source project in 2 seconds
technikhil314
technikhil314

Posted on • Edited on

Adding badges to your open source project in 2 seconds

Are you a open sourcer or maintainer for open source project?? Have you automated adding badges to your repo?? Let me know how you do it.

Adding badges to your readme file is such a pathetic and robotic feel job. I have seen people doing following

  1. Everytime go to shields.io or badgen.net
  2. Search for your badge by name e.g. travis
  3. Copy the url paste to your readme
  4. and format it to add links to proper destination etc etc

damn it took 45 seconds for me to type the process and may be 15 seconds for you to read all the steps. Imagine how much time it will take to add 10 badges.

I thought there must be some tool out there to do this but I did not find one (Please comment if you know of any such tool)

But I decided to created one such tool which will

  1. See for all files through your current working directory
  2. and add badges accordingly

Here is the demo of it running

How can you use it

  1. npm i -g git-auto-badger
  2. add a placeholder in your readme to tell where to add badges check the repo for more info
  3. run auto-badger

Done. All the necessary badges for any OSS project are addeddto your markdown. Commit and push. Njoy.

By necessary badges I mean following

Build status, Code coverage, NPM package version, Dependancies monitor, all contributors count, star on github, fork on github

visit https://github.com/technikhil314/auto-badger for more details. Feel free to give feedback or leave comment.

Top comments (0)