Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View jasonrudolph's full-sized avatar

Jason Rudolph jasonrudolph

View GitHub Profile
@jasonrudolph
jasonrudolph / 00-about-search-api-examples.md
Last active April 23, 2024 12:01
5 entertaining things you can find with the GitHub Search API
@jasonrudolph
jasonrudolph / git-branches-by-commit-date.sh
Created February 12, 2012 20:40
List remote Git branches and the last commit date for each branch. Sort by most recent commit date.
# Credit http://stackoverflow.com/a/2514279
for branch in `git branch -r | grep -v HEAD`;do echo -e `git show --format="%ci %cr" $branch | head -n 1` \\t$branch; done | sort -r
@jasonrudolph
jasonrudolph / about.md
Last active January 6, 2024 07:40
Programming Achievements: How to Level Up as a Developer
@jasonrudolph
jasonrudolph / gist:6057563
Last active December 15, 2023 14:52
GitHub Search API: Get the number of stars for a repository

James Sugrue [asked][1], "@GitHubAPI is there a way to find the number of stars for a given repository?"

Example

$ curl -ni "https://api.github.com/search/repositories?q=more+useful+keyboard" -H 'Accept: application/vnd.github.preview'
{
@jasonrudolph
jasonrudolph / request.sh
Created April 14, 2015 14:10
Get `starred_at` timestamp for a repository's stargazers via the GitHub API
curl https://api.github.com/repos/atom/atom/stargazers -H 'Accept: application/vnd.github.v3.star+json'

The Lean Startup - Notes, Quotes, and Choice Snippets

Characteristics of a lean startup:

  1. Uses "platforms enabled by open source and free software."

  2. Agile development

@jasonrudolph
jasonrudolph / 00-about.md
Created September 21, 2012 18:42
Rough Notes from Strange Loop 2012
@jasonrudolph
jasonrudolph / example-repository-redirects.md
Last active April 19, 2022 01:25
Preview Repository Redirects in the GitHub API

Repository redirects are coming to the GitHub API, and this functionality is now available for developers to preview. Let's try it out.

First, we need a repository that has been renamed or relocated. Since jasonrudolph/jasonrudolph.github.io was previously named jasonrudolph/jasonrudolph.com, we can use it as our guinea pig. 🌍🐖

We'll use curl for all of our examples below, and we'll include the --location option to instruct curl to follow any redirects that it encounters.

The Present

Using the current production version of the GitHub API, when we attempt to [access the repository](https://developer.github.com/v3/repos/#get

@jasonrudolph
jasonrudolph / heroku-ci-sample-timings-and-cost.md
Last active December 22, 2021 18:12
Sample timings and costs using various Heroku CI dyno types

Sample timings (in seconds)

Sample timings using Heroku CI for a small-ish Rails 6 app on various Heroku dyno types:

Dyno Type Run 1 Duration Run 2 Duration Run 3 Duration Average Duration
standard-1x 312 213 303 276
standard-2x 227 121 222 190
performance-m 162 164 175 167
performance-l 100 104 107 104
curl -H "Accept: application/vnd.github.v3.star+json" https://api.github.com/users/glaforge/starred