Skip to content

Instantly share code, notes, and snippets.

@webchick
Last active July 11, 2017 18:46
Show Gist options
  • Save webchick/1e937cbe8d5cc698aa00 to your computer and use it in GitHub Desktop.
Save webchick/1e937cbe8d5cc698aa00 to your computer and use it in GitHub Desktop.
Google BigQuery queries for Drupal GitHub data
# See: http://www.githubarchive.org / https://github.com/igrigorik/githubarchive.org/tree/master/bigquery
# Drupal-ish repos on GitHub: 10,491
SELECT repository_url, LEFT(repository_created_at, 7) AS month
FROM [githubarchive:github.timeline]
WHERE type = 'CreateEvent'
AND (repository_name CONTAINS 'drupal'
OR repository_description CONTAINS 'drupal')
GROUP BY repository_url, month
ORDER BY month DESC
# Drupal-ish pushes by month: ~5,500
SELECT LEFT(created_at, 7) as month, COUNT(*) as pushes
FROM [githubarchive:github.timeline]
WHERE type='PushEvent'
AND (repository_name CONTAINS 'drupal'
OR repository_description CONTAINS 'drupal')
GROUP BY month
ORDER BY month DESC
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment