Introduction
A GitHub personal home page, officially called a profile, is a personal GitHub presentation master page written in Markdown
. In this article, we’ll demonstrate how to add a year progress (automatically updated every day) to the GitHub profile page—so it looks like this:

|
|
Pre-Conditions
- GitHub Accounts
- A GitHub Repository with the same name as your GitHub username (see my another blog post Add a Funny Snake Animation to Your GitHub Profile Page for tutorials)
Implementation Steps
We need to add two files to the repository (we mentioned above): one is the workflows file that implements automatic updating of the year progress bar, and the other is the index.js file that sets the style of the generated year progress bar.
Step 0: Find GitHub Email Prefix
Before implementing the year progress bar, you’ll first need to locate your GitHub email prefix - we’ll use this in the following steps.
- Log in to your GitHub account.
- Click on your avatar in the top-right corner → “Settings” → “Emails”.
- Under “Keep my email addresses private,” locate the noreply email address formatted as [numeric ID]+[username]@users.noreply.github.com.
- The [numeric ID] (e.g., 12345678) is your GitHub email prefix.
After finding the GitHub email prefix, let’s start the implementations of year progress bar.
Step 1: Create Workflows
Firstly, let’s focus on the workflows file.
- Click the
Add file
button in the repository and selectCreate new file
to create a new file. - Name the newly created file by entering
.github/workflows/main.yml
(the file name includes the path where the file is located). - Add the following code to the
yml
file:
|
|
- Replace the GitHub email prefix YOUR_ID in line 24 of the code
git config user.email 'YOUR_ID+github-actions[bot]@users.noreply.github.com'
with your own GitHub email prefix derived in Step 0.
Step 2: Create index.js
Secondly, let’s focus on the index.js file.
- Create another file in the repository named
index.js
(the same directory asREADME.md
). - Add the following code into the file:
|
|
- Please note the line
const readme =
! Here const readme will fully coversREADME.md
. Therefore, please concatenate the original contents in README.md in index.js (at “/* Add something originally in the README.md file. */ “), rather than just the progress bar. - Click on
Actions
button in the repository, Test theProgress Bar CI
workflows, and Check whether implemented successfully.
Debugging for the Potential Problems
Failed at Commit change & Push
When I attempted to run the Progress Bar CI
workflows, I found an error, in detail:
|
|
Solutions
- Add the following codes in
.github/workflows/main.yml
(add a write-enabled permission configuration to the workflows):
|
|
- The updated
yml
would be:
|
|
- Then run the
Progress Bar CI
workflows again and check. I find the problem solved.
Copyright Notice
The original code was developed by GitHub user 👉👉 @liununu. All credits go to the author.