Using gitqlite
, query for percentage of commit count by author (in this case in facebook/react
). Limit to top 25, include a "chart"
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Verifying my Blockstack ID is secured with the address 1NKAeaGUag7tpGxpy6unSrAWRZhXJe5JQx https://explorer.blockstack.org/address/1NKAeaGUag7tpGxpy6unSrAWRZhXJe5JQx |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const names = ["world", "patrick", "deno", "adhoc"] | |
names.forEach(n => console.log(`hello, ${n}!`)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_nnnn_ | |
dGGGGMMb ,""""""""""""""""""""""""""""". | |
@p~qp~~qMb | // TODO make this better 🎉 | | |
M|@||@) M| _;.............................' | |
@,----.JM| -' | |
JS^\__/ qKL | |
dZP qKRb | |
dZP qKKb | |
fZP SMMb | |
HZM MMMM |
AskGit is a tool looking for more (interesting) use cases.
This gist takes a look at the email domains of contributors to two major open source code bases (Linux and Kubernetes).
askgit-query.sql
can be piped into the askgit
command to produce the output in k8s-SHA.txt
and linux-SHA.txt
Commit Count
is the total number of commits by contributors with an email address fromDomain
Unique Emails
is the number of unique contributors with an email fromDomain
Domain
is the email domain
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT | |
count(*), | |
substr(author_email, instr(author_email, '@')+1) AS email_domain -- https://sqlite.org/lang_corefunc.html | |
FROM commits | |
WHERE parent_count < 2 -- ignore merge commits | |
GROUP BY email_domain | |
ORDER BY count(*) DESC |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT | |
name, primary_language, | |
github_repo_file_content('google', name, 'go.mod') as go_mod | |
FROM github_org_repos('google') | |
WHERE primary_language = 'Go' |
Uses mergestat
to access the GitHub API and go-mysql-server
.
Currently, only stargazers
table is available.
GitHub token used is from a "bot" account.
Hosted on Fly.
Username: root
Password: github
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- enable plv8 extension | |
CREATE EXTENSION plv8; | |
-- define plv8_yaml_to_json() UDF using implementation from: https://github.com/nodeca/js-yaml | |
CREATE OR REPLACE FUNCTION plv8_yaml_to_json(yaml_input TEXT) RETURNS JSONB AS $$ | |
/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */ function isNothing(e){return null==e}function isObject(e){return"object"==typeof e&&null!==e}function toArray(e){return Array.isArray(e)?e:isNothing(e)?[]:[e]}function extend(e,t){var n,r,o,a;if(t)for(n=0,r=(a=Object.keys(t)).length;n<r;n+=1)e[o=a[n]]=t[o];return e}function repeat(e,t){var n,r="";for(n=0;n<t;n+=1)r+=e;return r}function isNegativeZero(e){return 0===e&&Number.NEGATIVE_INFINITY===1/e}var isNothing_1=isNothing,isObject_1=isObject,toArray_1=toArray,repeat_1=repeat,isNegativeZero_1=isNegativeZero,extend_1=extend,common={isNothing:isNothing_1,isObject:isObject_1,toArray:toArray_1,repeat:repeat_1,isNegativeZero:isNegativeZero_1,extend:extend_1};function formatError(e,t){var n="",r=e.reason||"(unknown reason)";re |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"__inputs": [ | |
{ | |
"name": "DS_MERGESTAT_INTERNAL", | |
"label": "MergeStat Internal", | |
"description": "", | |
"type": "datasource", | |
"pluginId": "postgres", | |
"pluginName": "PostgreSQL" | |
} |
OlderNewer