How GitHub Sync Works#
In GitHub, your profile README lives in a special repository matching your exact username:
BASH
MonoForge provides an authenticated REST API workflow that reads and updates this repository directly without requiring manual copy-pasting.
Remote Diff Preview#
When you click Connect GitHub or Push to GitHub:
- MonoForge queries the GitHub REST API (
GET /repos/{owner}/{repo}/contents/README.md). - It retrieves the current live markdown file from your repository.
- It displays an interactive, color-coded side-by-side diff viewer (
DiffPreview.tsx) showing:
- Green lines: Additions and newly inserted widgets.
- Red lines: Removals.
- Unchanged lines: Context surrounding the edits.
Executing the Commit#
Once you review the diff:
- Enter your custom commit message (default:
chore: update profile README via MonoForge). - Click Confirm & Push.
- MonoForge sends an authenticated
PUTrequest to GitHub updating the file with SHA integrity checks. - Your live GitHub profile updates instantly.
