Personalize selection, visualization and dynamic ordering of repository pins for public and private GitHub profiles.
No PAT required, just copy the workflow or repo template for efficient data fetching and visualization rendering.
Supports multi-language displaying of private and public repository pins for both user and organisation profiles.
Supports profile website deployment for full utilization of the frequently updated repository pin visualization features.
Pins can be customized by repo selection, stats, order, background image (URL or path), and available themes.
Repository data is fetched from GitHub API. Contribution data is scraped from commit logs.
Copy the workflow <workflow>.yml to .github/workflows/ in a user/org profile repository:
name: generate-profile-repo-pins
on:
schedule:
- cron: "0 0 * * *"
workflow_dispatch:
permissions:
contents: write
jobs:
update-pins:
runs-on: ubuntu-latest
steps:
- uses: profile-icons/readme-repo-pins-src@v1
with:
gh_api_token: ${{ secrets.GH_API_TOKEN || secrets.GITHUB_TOKEN }} # required, uses default fallback
gh_username: ${{ secrets.GH_USERNAME || github.repository_owner }} # required, uses default fallback
theme: ${{ secrets.THEME }} # optional
background_image: ${{ secrets.BG_IMG }} # optional
num_repo_pins: ${{ secrets.NUM_REPO_PINS }} # optional
repo_pin_order: ${{ secrets.REPO_PIN_ORDER }} # optional
repo_names_exclusive: ${{ secrets.REPO_NAMES_EXCLUSIVE }} # optional
is_exclude_repos_owned: ${{ secrets.IS_EXCLUDE_REPOS_OWNED }} # optional
is_exclude_repos_contributed: ${{ secrets.IS_EXCLUDE_REPOS_CONTRIBUTED }} # optional
is_contribution_stats: ${{ secrets.IS_CONTRIBUTION_STATS }} # optional
The workflow execute the action.yml and source code in this repo.
- Simply create a copy of the template repository by clicking here
- name the new repository
Repository name*identical to theowner*name. - select the green
Create Repositorybutton.
- name the new repository
The template repo (and generated copies) execute the source code in this repo.
The source code creates a profile with frequently updated repo pins using CI automation and a placeholder:
<!-- START: REPO-PINS -->
<!-- END: REPO-PINS -->
If you want an auto-updated GitHub profile, ensure the placeholder is in a README.md file.
If you want a GitHub Pages profile, ensure the placeholder is in an index.md file.
The files should be located in:
/root directory for GitHub user profile and GitHub Pages profile/profiledirectory for a GitHub organisation profile.
There is no further setup requirement aside for optional configurations.
The repository project was initially created to streamline the display of generated pin visualizations on a
private profile README.md, but supports broader use cases with optional personalization and elevation of API privileges.
The optional THEME configuration controls the visual color scheme of the generated SVG pin background, border, text, and icon features.
This can be set by creating a GitHub Action with the following key-value field pairs:
- key:
THEME - value (either one of the two formats):
{<owner/repo>: <theme_name>}- individual pin theme(s)<theme_name>- single theme for pin(s)
where:
owner/repomatches the owner/repository names in the URL of a given repository - required<>theme_namematches any key infiles/themes.json- required<>
If a theme is unavailable, you can add it to
files/themes.json- refer here for more information.
The default
THEMEisgithub_soft
The optional BG_IMG configuration controls the embedding of select imagery to the background of the generated SVG pin(s).
This can be set by creating a GitHub Action with the following key-value field pairs:
- key:
BG_IMG - value (either one of the three formats):
{<owner/repo>: <img-config-dict>}- individual pin background image(s)<img-config-dict>- single background image for pin(s)<url/filepath>- single background image for pin(s)
where:
owner/repomatches the owner/repository names in the URL of a given repository - required<>img-config-dictis any stringified dictionary configuration matching the following format
{
"img": <url/filepath>,
"align": [align],
"mode": [mode],
"opacity": [opacity]
}
url/filepathis either an image URL or the path to an image file uploaded (to an owned repo) - required<>alignis any align keyword value in preserveAspectRatio attribute - optional[](defaultxMidYMid)modeis any CSS object-fit property value in[cover, contain, stretch]- optional[](defaultstretch)opacityis a float value between0and1.0- optional[](default0.25)
The default
BG_IMGisNone(which defaults to theTHEMEbackground color)
The optional REPO_NAMES_EXCLUSIVE configuration controls the exclusive generation of pins for a given list of repository names.
This can be set by creating a GitHub Action with the following key-value field pairs:
- key:
REPO_NAMES_EXCLUSIVE - value:
<owner/repo>,...,<owner/repo>
where:
owner/repomatches the owner/repository names in the URL of a given repository - required<><owner/repo>,...,<owner/repo>is a list of any number ofowner/reposeparated by commas,
The optional IS_CONTRIBUTION_STATS configuration controls whether a (user) contribution percentage is appended to
the repository contributor count in the pin footer, enclosed in parentheses, such as: 22 (99.9%).
This can be set by creating a GitHub Action with the following key-value field pairs:
- key:
IS_CONTRIBUTION_STATS - value:
[is_stats]
where:
is_statsis eithertrue(any value) orfalse(empty) - optional[]
The default
IS_CONTRIBUTION_STATSisfalse
The optional GH_API_TOKEN configuration is for elevating GitHub GraphQL API privileges with a personal access token (PAT)
The default rate limit when not using a GitHub PAT is 1000 query points per hour and is limited to public repository data.
The rate limit when using a PAT is increased to 5000, and provides access to authorized private repository data so that pins can be generated for both
public and private repositories to both public and private profiles.
This can be set by creating a GitHub Action with the following key-value field pairs:
- key:
GH_API_TOKEN - value:
[PAT]
where:
PATis a GitHub personal access token and can be generated here - optional[]
The default
GH_API_TOKENisGITHUB_TOKEN(1000 GraphQL API query points per hour)
A
PATis required for displaying private repository pins
The optional NUM_REPO_PINS configuration controls the maximum possible numbREADME.mder of repository pins to generate up to a hard limit of 100.
This can be set by creating a GitHub Action with the following key-value field pairs:
- key:
NUM_REPO_PINS - value:
[num]
where:
numis any int value greater than0- optional[]
The default
NUM_REPO_PINSis6
Overruled by the
REPO_NAMES_EXCLUSIVEconfiguration when default, or the minimum value between both when also set.
The optional REPO_PIN_ORDER configuration controls the dynamic ordering of generated repository pin visualizations.
This can be set by creating a GitHub Action with the following key-value field pairs:
- key:
REPO_PIN_ORDER - value:
[order]
where:
orderis optionally any value in:stargazers- the number of stars the repo hasname- the repo namecreated_at- the datetime the repo is initially createdupdated_at- the datetime the repo is last updatedpushed_at- the datetime the repo is last pushed torandom- any random order
The default
REPO_PIN_ORDERisSTARGAZERS
Overruled by the
REPO_NAMES_EXCLUSIVEconfiguration when default, but not when also set.
By default, repository data collected for generating pin visualizations is first those pinned by a user, followed by other repositories owned by the user, and then other repositories the user has contributed to but does not own.
The optional IS_EXCLUDE_REPOS_OWNED configuration controls whether repositories owned by a user but not pinned are excluded.
This can be set by creating a GitHub Action with the following key-value field pairs:
- key:
IS_EXCLUDE_REPOS_OWNED - value:
[is_exclude]
where:
is_excludeis eithertrue(any value) orfalse(empty) - optional[]
The default
IS_EXCLUDE_REPOS_OWNEDisfalse
Overruled by the
REPO_NAMES_EXCLUSIVEconfiguration, as pin visuals are generated only for listed repositories.
By default, repository data collected for generating pin visualizations is first those pinned by a user, followed by other repositories owned by the user, and then other repositories the user has contributed to but does not own.
The optional IS_EXCLUDE_REPOS_CONTRIBUTED configuration controls whether repositories contributed to but not owned by a user are excluded.
This can be set by creating a GitHub Action with the following key-value field pairs:
- key:
IS_EXCLUDE_REPOS_CONTRIBUTED - value:
[is_exclude]
where:
is_excludeis eithertrue(any value) orfalse(empty) - optional[]
The default
IS_EXCLUDE_REPOS_CONTRIBUTEDisfalse
Overruled by the
REPO_NAMES_EXCLUSIVEconfiguration, as pin visuals are generated only for listed repositories.
The optional GH_USERNAME configuration controls which (pinned/owned/contributed to) repositories are displayed by association.
This can be set by creating a GitHub Action with the following key-value field pairs:
- key:
GH_USERNAME - value:
[username]
where:
usernamemust match the username associated with repositories pinned/owned/contributed to by the user the pin display focuses on - optional[]
The default
GH_USERNAMEisgithub.repository_owner(the username associated with the owner of the repo)
GH_USERNAMEis required for displaying pins on an organisation profile