Development
This project uses a Makefile for common development tasks.
Setup
make install # Install runtime dependencies
make dev # Install in development mode (editable install)
Testing
make test # Run tests with pytest
Building Binaries
Standalone executables are built automatically on release via GitHub Actions. To build locally:
pip install pyinstaller
pip install -e .
pyinstaller --onefile --name gitfetch --paths src run.py
Development Workflow
- Clone the repository
- Run
make devto set up development environment - Make your changes
- Run
make testto ensure tests pass
Project Structure
gitfetch/
├── .github/workflows/ # CI/CD workflows (ci, release, pages)
├── src/gitfetch/ # Main package
│ ├── __init__.py
│ ├── cli.py # Command line interface
│ ├── config.py # Configuration handling
│ ├── cache.py # SQLite caching
│ ├── fetcher.py # API data fetching
│ ├── display.py # Terminal display logic
│ ├── providers.py # Provider definitions
│ └── text_patterns.py # ASCII art patterns
├── tests/ # Unit tests
├── docs/ # Documentation site
├── run.py # PyInstaller entry point
├── pyproject.toml # Project configuration
├── setup.py # Setup script
├── Makefile # Development tasks
├── flake.nix / flake.lock # Nix flake
└── CHANGELOG.md # Release changelog
Contributing
Contributions are welcome! Please:
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests if applicable
- Ensure all tests pass
- Submit a pull request
License
This project is licensed under GPL-2.0. See LICENSE for details.