Created
September 12, 2025 00:04
-
-
Save briandfoy/ce386d9014e372eb2a5c0cfb711f165f to your computer and use it in GitHub Desktop.
Find the days you did not contribute to 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
#!/bin/sh | |
USER=${GITHUB_USER} | |
FROM=$(date -u +"%Y-01-01T00:00:00Z") | |
TO=$(date -u +"%Y-%m-%dT%H:%M:%SZ") | |
gh api graphql -f query=' | |
query($login:String!,$from:DateTime!,$to:DateTime!){ | |
user(login:$login){ | |
contributionsCollection(from:$from,to:$to){ | |
contributionCalendar{ | |
weeks{ | |
contributionDays{ date contributionCount } | |
} | |
} | |
} | |
} | |
}' -F login="$USER" -F from="$FROM" -F to="$TO" \ | |
| jq -r '.data.user.contributionsCollection.contributionCalendar.weeks[] | |
.contributionDays[] | select(.contributionCount==0) | .date' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment