Skip to main content

gh_badges()

Markdown image links for GitHub profile summary cards.

Usage

Source

gh_badges(
    username,
    badge,
    theme="default",
)

Cards come from github-profile-summary-cards.

Parameters

username: str

GitHub username.

badge: str or list of str

One or more of "details", "commit_lang", "ptime", "repo_lang", or "stats".

theme: str = "default"
"default", "dark", or "light".

Returns

str
Markdown, one badge per line.

Raises

ValueError
If a badge or theme name is unknown.

Examples

>>> print(gh_badges("mjfrigaard", ["details", "stats"], theme="dark"))