Skip to main content

A few useful GitHub searches

For good and for ill, GitHub dominates the open source world. A huge amount of open source code is available there, even if it’s only a mirror or a fork of a project that’s primarily maintained elsewhere – and that makes it available to GitHub search.

I use GitHub search multiple times a day, and I find it an invaluable tool. I have a couple of shortcuts set up in Alfred so I can search even faster:

A search box with the query 'gh ExpressionAttributeValues' and a single result highlighted in red: 'Search GitHub for ExpressionAttributeValues'.

I set up these shortcuts with Alfred’s web search features; any good launcher should be able to set up similar shortcuts if you’d find that convenient. Setting up the shortcut isn’t really the point of this post; how I search GitHub is.

These are a couple of searches I find especially useful:

GitHub code search is far from perfect, but it’s good enough to be useful and it’s helped me out a bunch of times. It’s hard to imagine going back to a time where I don’t have a large corpus of similar code to search when I get stuck on something tricky.