I had a little fun with the GitHub API last night: I created a small plug-in for WordPress called GitPress that provides a sidebar widget.  The widget can be configured to show a list of repositories for any user on GitHub.  It was pretty simple but it was a nice exercise because I learned a lot from it:

And all of this took me just a couple of hours after work.  I got into a programming flow and I had fun.  And now my mind is imagining many other cool things that I could do with it:

  • Make it possible to have multiple instances of the widget with different settings.  (I just finished this today!)
  • Display more information than just a link to the repository (e.g. number of forks, number of watchers) and allow the user to choose how to format that information.
  • Create another widget that displays news feed items for a GitHub user.
  • Create another widget that displays recent commits for a project.

Some of this doesn’t seem possible through the current GitHub API but there are plans to add more features.  Hopefully I can leverage the new features to build even cooler integrations with WordPress.

Tags: , ,