6.3 KiB
6.3 KiB
summary, read_when
| summary | read_when | |||
|---|---|---|---|---|
| Fork quick start: differences, commands, and planned features. |
|
CodexBar Fork - Quick Start Guide
Fork Maintainer: Brandon Charleson (topoffunnel.com)
Original Author: Peter Steinberger (steipete)
Fork Repository: https://github.com/topoffunnel/CodexBar
🎯 What Makes This Fork Different?
Key Enhancements
- Augment Provider Support - Full integration with Augment Code API
- Enhanced Security - Improved keychain handling, no permission prompts
- Better Cookie Management - Automatic session keepalive, Chrome Beta support
- Bug Fixes - Cursor bonus credits, cookie domain filtering
Planned Features
- Multi-account management per provider
- Enhanced diagnostics and logging
- Upstream sync automation
- Usage history tracking
🚀 Quick Commands
Development
# Build and run (kills old instances, builds, tests, packages, relaunches)
./Scripts/compile_and_run.sh
# Quick build
swift build
# Run tests
make test
# Format code
swiftformat Sources Tests
swiftlint --strict
# Package app
./Scripts/package_app.sh
# Restart app after rebuild
pkill -x CodexBar || pkill -f CodexBar.app || true
cd /Users/steipete/Projects/codexbar && open -n /Users/steipete/Projects/codexbar/CodexBar.app
Release
# Edit .mac-release.env first: MAC_RELEASE_REPO, feed URL, download URL,
# bundle id, and Sparkle public/signing key must point at your fork.
./Scripts/release.sh
# See full release process
cat docs/RELEASING.md
Git Workflow
# Check status
git status
# Create feature branch
git checkout -b feature/my-feature
# Commit changes
git add -A
git commit -m "feat: description"
# Push to fork
git push origin feature/my-feature
# Sync with upstream (TBD - see docs/FORK_ROADMAP.md Phase 4)
📁 Key Files & Directories
Source Code
Sources/CodexBar/- Swift 6 menu bar appSources/CodexBarCore/- Core logic, providers, utilitiesSources/CodexBarCore/Providers/Augment/- Augment provider implementationTests/CodexBarTests/- XCTest coverage
Scripts
Scripts/compile_and_run.sh- Main development scriptScripts/package_app.sh- Package app bundleScripts/sign-and-notarize.sh- Release signingScripts/make_appcast.sh- Generate appcast XML
Documentation
docs/augment.md- Augment provider guidedocs/FORK_ROADMAP.md- Development roadmapdocs/RELEASING.md- Release processdocs/DEVELOPMENT.md- Build instructionsREADME.md- Main documentation
🔧 Common Tasks
Adding a New Feature
- Create feature branch:
git checkout -b feature/my-feature - Make changes in
Sources/ - Add tests in
Tests/ - Run
./Scripts/compile_and_run.shto verify - Run
swiftformat Sources Tests && swiftlint --strict - Commit with descriptive message
- Push and create PR
Debugging Augment Issues
- Enable debug logging:
export CODEXBAR_LOG_LEVEL=debug - Check Console.app for "com.steipete.codexbar"
- Use Settings → Debug → Augment → Show Debug Info
- Check
docs/augment.mdtroubleshooting section
Testing Changes
# Run all tests
make test
# Run specific test
swift test --filter AugmentTests
# Build and test together
./Scripts/compile_and_run.sh --test
Updating Documentation
- Edit relevant
.mdfile indocs/ - Update
README.mdif needed - Commit with
docs:prefix - No need to rebuild app
🐛 Troubleshooting
App Won't Launch
# Kill all instances
pkill -x CodexBar || pkill -f CodexBar.app || true
# Rebuild and relaunch
./Scripts/compile_and_run.sh
Build Errors
# Clean build
swift package clean
swift build
# Check for format issues
swiftformat Sources Tests --lint
swiftlint --strict
Cookie Issues (Augment)
- Check browser is logged into app.augmentcode.com
- Verify cookie source in Settings → Providers → Augment
- Try manual cookie import (see
docs/augment.md) - Check debug logs for cookie import details
Keychain Permission Prompts
- This fork includes fixes to eliminate prompts
- If you still see prompts, check
Sources/CodexBarCore/Keychain/ - Ensure you're running the latest build
📚 Learning Resources
Understanding the Codebase
- Start with
Sources/CodexBar/CodexbarApp.swift- App entry point - Review
Sources/CodexBarCore/UsageStore.swift- Main state management - Check
Sources/CodexBarCore/Providers/- Provider implementations - Read
docs/provider.md- Provider authoring guide
Swift 6 & SwiftUI
- Uses
@Observablemacro (notObservableObject) - Prefer
@Stateownership over@StateObject - Use
@Bindablein views for two-way binding - Strict concurrency checking enabled
Coding Style
- 4-space indentation
- 120-character line limit
- Explicit
selfis intentional (don't remove) - Follow existing
MARKorganization - Use descriptive variable names
🤝 Contributing
To This Fork
- Fork the fork repository
- Create feature branch
- Make changes with tests
- Submit PR to
topoffunnel/CodexBar
To Upstream
- Check if feature benefits all users
- Create PR to
steipete/CodexBar - Reference this fork if relevant
- Be patient with review process
See docs/FORK_ROADMAP.md for contribution strategy.
📞 Support
Fork-Specific Issues
- GitHub Issues: https://github.com/topoffunnel/CodexBar/issues
- Email: [your-email]@topoffunnel.com
Upstream Issues
- GitHub Issues: https://github.com/steipete/CodexBar/issues
- Twitter: @steipete
📋 Next Steps
- Read the Roadmap:
docs/FORK_ROADMAP.md - Set Up Development:
./Scripts/compile_and_run.sh - Review Augment Docs:
docs/augment.md - Check Current Issues: GitHub Issues tab
- Join Development: Pick a task from Phase 2-5
🎉 Quick Wins
Want to contribute but not sure where to start? Try these:
- Add more test coverage for Augment provider
- Improve error messages in cookie import
- Add screenshots to
docs/augment.md - Test on different macOS versions
- Report bugs you find
- Suggest UI improvements
Happy coding! 🚀