This guide helps you track changes, analyze PRs, and contribute to the embabel project.
~/github/jmjava/
├── embabel-learning/ # Your embabel learning workspace
│ ├── scripts/ # All monitoring and management scripts
│ ├── docs/ # Documentation and guides
│ └── notes/ # Your personal learning notes
├── guide/ # Your fork of embabel/guide
├── embabel-agent/ # Your fork of embabel/embabel-agent
└── [other embabel repos] # Other forked repositories
Best for:
- 📜 Viewing file history and blame annotations
- 🔍 Comparing branches visually
- 👀 Seeing who changed what and when
- 🎯 Understanding code evolution
How to use:
- Hover over any line to see commit info
- Click "Open Changes" in GitLens sidebar
- Use Command Palette: "GitLens: Compare References" to compare branches
- Click on file annotations to see detailed commit history
Best for:
- 📋 Listing and reviewing PRs
- 💬 Reading PR comments and reviews
- 🧪 Checking out PRs locally for testing
- 🏷️ Tracking releases
Key commands:
# List open PRs
gh pr list --repo embabel/guide
# View specific PR
gh pr view 123 --repo embabel/guide
# Checkout PR locally to test
gh pr checkout 123 --repo embabel/guide
# View PR diff
gh pr diff 123 --repo embabel/guide
# List releases
gh release list --repo embabel/guideBest for:
- 🔄 Syncing your fork with upstream
- 🆚 Comparing your changes with upstream
- 🔀 Merging upstream changes
Best for:
- 👁️ Watching repositories (click Watch → Custom → select events)
- 🔔 Getting notifications for new PRs/issues
- 💭 Participating in discussions
- 📊 Viewing insights and contributor graphs
# Run the monitoring script
~/github/jmjava/embabel-learning/scripts/monitor-embabel.sh
# Or if you've set up aliases: emThis shows you:
- New PRs opened
- Recent commits in upstream
- New releases
- Your unpushed changes
-
Review all open PRs:
cd ~/github/jmjava/guide gh pr list --repo embabel/guide cd ~/github/jmjava/embabel-agent gh pr list --repo embabel/embabel-agent
-
Analyze interesting PRs:
~/github/jmjava/embabel-learning/scripts/view-pr.sh guide 123 -
Compare your fork with upstream:
~/github/jmjava/embabel-learning/scripts/compare-branches.sh all -
Sync your fork with upstream:
~/github/jmjava/embabel-learning/scripts/sync-upstream.sh all
cd ~/github/jmjava/guide
gh pr checkout 123 --repo embabel/guide
# Test it...
mvn clean install
# or whatever tests you need
# Go back to your branch
git checkout main # or your working branch# Read the main READMEs
cat ~/github/jmjava/guide/README.md
cat ~/github/jmjava/embabel-agent/README.md
# Look for contributing guides
find ~/github/jmjava/guide -name "CONTRIBUTING.md"
find ~/github/jmjava/embabel-agent -name "CONTRIBUTING.md"- Open GitLens "File Heatmap" to see which files change most
- These are usually the core files you should understand first
- Right-click any file → "Open File History" to see its evolution
# Watch how a specific file evolves
cd ~/github/jmjava/guide
git log --follow -p -- src/main/kotlin/com/embabel/guide/chat/ChatService.kt
# See who's the expert on a file
git log --format='%an' -- <file> | sort | uniq -c | sort -rn- Go to https://github.com/embabel/guide
- Click "Watch" → "Custom"
- Select:
- ✅ Releases
- ✅ Pull requests
- ✅ Issues (if you want)
- Repeat for embabel-agent
cd ~/github/jmjava/guide
git checkout -b learning/experiments
# Now you can:
# - Add comments to understand code
# - Try modifications
# - Break things safely
# - Commit your learning notesShows comprehensive status of both repos.
~/github/jmjava/monitor-embabel.shMerges upstream changes into your fork.
# Sync both repos
~/github/jmjava/sync-upstream.sh all
# Sync only guide
~/github/jmjava/sync-upstream.sh guide
# Sync only embabel-agent
~/github/jmjava/sync-upstream.sh agentDetailed analysis of a specific PR.
# View PR #123 in guide repo
~/github/jmjava/view-pr.sh guide 123
# View PR #456 in embabel-agent repo
~/github/jmjava/view-pr.sh agent 456See differences between your fork and upstream.
# Compare both repos
~/github/jmjava/compare-branches.sh all
# Compare only guide
~/github/jmjava/compare-branches.sh guide-
File Annotations (always visible)
- See commit info next to each line
- Toggle with: Command Palette → "GitLens: Toggle File Blame"
-
Compare with Branch
- Command Palette → "GitLens: Compare References"
- Compare:
HEADwithupstream/main - See all differences visually
-
File History
- GitLens sidebar → "File History" view
- Click any commit to see changes
- Use timeline slider to travel through time
-
Search Commits
- GitLens sidebar → "Search & Compare"
- Search by: message, author, file, change
-
Contributors View
- See who's working on what
- Identify domain experts
A workspace lets you open multiple repos in one Cursor window, making it easier to navigate between them.
The workspace file has been created for you at:
~/github/jmjava/embabel-workspace.code-workspace
To use it:
# Easy way (from embabel-learning):
eworkspace
# Or manually:
cursor ~/github/jmjava/embabel-workspace.code-workspace
# Or from anywhere:
cd ~/github/jmjava
cursor embabel-workspace.code-workspaceWhat's included:
- 📘 guide - Your fork of embabel/guide
- 🤖 embabel-agent - Your fork of embabel/embabel-agent
- 🎓 embabel-learning - This learning workspace
Workspace features:
- ✅ GitLens configured for all repos
- ✅ Optimized file exclusions (target/, .git/, etc.)
- ✅ Recommended extensions (GitLens, GitHub PR, Copilot, Java, Kotlin)
- ✅ Easy navigation between repos in sidebar
If you prefer to work on one repo at a time:
# Open just guide
cd ~/github/jmjava/guide
cursor .
# Open just embabel-agent
cd ~/github/jmjava/embabel-agent
cursor .
# Open embabel-learning
cd ~/github/jmjava/embabel-learning
cursor .With workspace:
- ✅ See all repos in one window
- ✅ Search across all repos
- ✅ Compare code between repos
- ✅ Unified GitLens view
Without workspace:
- ✅ Simpler, one repo at a time
- ✅ Less resource usage
- ✅ Faster for focused work
- ✅ Set up monitoring (Done!)
- ⬜ Run both projects locally
- ⬜ Read all README files
- ⬜ Look at recent PRs to understand common changes
- ⬜ Find the main entry points (Application.kt files)
- ⬜ Use GitLens to identify "hot" files
- ⬜ Read those files thoroughly
- ⬜ Create a diagram of how components connect
- ⬜ Run tests locally
- ⬜ Make a tiny change and see what breaks
- ⬜ Find "good first issue" labels
- ⬜ Analyze how similar issues were fixed
- ⬜ Make your first PR
- ⬜ Learn from code review feedback
- ⬜ Pick a component to become expert in
- ⬜ Read all related PRs for that component
- ⬜ Review PRs that touch your component
- ⬜ Help others with questions about it
-
Set up aliases using the provided script:
source ~/github/jmjava/embabel-learning/scripts/setup-aliases.sh source ~/.bash_aliases
This adds:
em,esync,ecompare,elist,efork,eclone, and more -
Set up git commit template for embabel conventions:
cd ~/github/jmjava/guide # Look at recent commits to learn the style git log --oneline -20
-
Watch the contributors you find in GitLens:
- Go to their GitHub profiles
- Click "Follow"
- See what they work on
-
Use GitHub CLI for notifications:
# See your notification gh notify # List issues assigned to you gh issue list --assignee @me
-
Create a learning journal:
# In each repo cd ~/github/jmjava/guide touch LEARNING.md # Document your discoveries, questions, insights
- GitHub CLI Manual:
gh helpor https://cli.github.com/manual/ - GitLens Documentation: https://gitlens.amod.io/
- Git Fork Workflow: https://www.atlassian.com/git/tutorials/comparing-workflows/forking-workflow
| Task | Command |
|---|---|
| Daily check | ~/github/jmjava/monitor-embabel.sh |
| Sync with upstream | ~/github/jmjava/sync-upstream.sh all |
| View PR | ~/github/jmjava/view-pr.sh guide 123 |
| Compare branches | ~/github/jmjava/compare-branches.sh all |
| List PRs | gh pr list --repo embabel/guide |
| Checkout PR | gh pr checkout 123 --repo embabel/guide |
| View releases | gh release list --repo embabel/guide |
| Your notifications | gh notify |
Happy Learning! 🎉
Remember: The best way to learn a codebase is to:
- 📖 Read it
- 🔧 Break it
- 🐛 Fix it
- 🚀 Improve it