Ways to Contribute
There are many ways to contribute to neo-git-graph:- Report bugs - Found an issue? Let us know!
- Suggest features - Have an idea? We’d love to hear it
- Improve documentation - Help others understand the extension
- Submit code - Fix bugs or implement new features
- Review PRs - Help review contributions from others
Getting Started
Fork the repository
Fork the repository on GitHub:github.com/asispts/neo-git-graphClick the Fork button in the top-right corner.
Install dependencies
Neo-git-graph uses pnpm for package management:
The project requires Node.js 22 and uses pnpm 10.29.3 (configured via
packageManager in package.json).Development Workflow
Project Structure
Available Scripts
Running the Extension
Start debugging
Press
F5 or go to Run and Debug → Run ExtensionThis opens a new VS Code window with the extension loaded.Test your changes
In the Extension Development Host window:
- Open a Git repository
- Run Neo Git Graph: View Git Graph (git log)
- Verify your changes work as expected
Code Quality Standards
Neo-git-graph maintains high code quality through automated checks:Linting
The project uses oxlint for fast, accurate linting:Formatting
The project uses oxfmt for consistent code formatting:Type Checking
All code must pass TypeScript type checking:src/ and web/ directories.
Continuous Integration
All pull requests must pass CI checks:- Type checking - Ensures no TypeScript errors
- Linting - Enforces code quality rules
- Formatting - Verifies consistent code style
- Every push to
main - Every pull request to
main - Node.js 22
.github/workflows/ci.yaml for the full CI configuration.
Making Changes
Creating a Branch
feature/add-commit-search- New featuresfix/avatar-cache-bug- Bug fixesdocs/update-readme- Documentation changesrefactor/cleanup-datasource- Code refactoring
Writing Code
Extension Code (src/)
Extension Code (src/)
The
src/ directory contains the extension’s backend code:- extension.ts - Extension activation and commands
- dataSource.ts - Git command execution (git log, git branch, etc.)
- repoManager.ts - Repository detection and workspace management
- gitGraphView.ts - WebView management
- config.ts - Reading VS Code settings
- Use
getConfig()to read settings - Execute Git commands via
DataSourceclass - Return promises for async operations
- Handle errors gracefully
WebView Code (web/)
WebView Code (web/)
The
web/ directory contains the UI code that runs in the webview:- Renders the commit graph visualization
- Handles user interactions (clicks, scrolling)
- Communicates with extension via message passing
Configuration (package.json)
Configuration (package.json)
The
package.json defines:- Extension metadata (name, version, description)
- Commands contributed by the extension
- Configuration settings (all prefixed with
neo-git-graph.) - Activation events
contributes.configuration.propertiesin package.jsonconfig.tsgetter method
Commit Guidelines
Write clear, descriptive commit messages:feat:- New featurefix:- Bug fixdocs:- Documentation changesrefactor:- Code refactoringtest:- Test changeschore:- Build/tooling changes
Submitting a Pull Request
Create a pull request
Go to your fork on GitHub and click New Pull Request.Select:
- Base repository:
asispts/neo-git-graph - Base branch:
main - Head repository:
YOUR-USERNAME/neo-git-graph - Compare branch:
feature/your-feature-name
Write a clear description
Describe:
- What the PR does
- Why the change is needed
- How to test it
- Any breaking changes
Wait for CI checks
GitHub Actions will automatically run:
- Type checking
- Linting
- Formatting
Reporting Issues
Found a bug? Create an issue. Include:- Clear title - “Graph doesn’t refresh after commit” (not “broken”)
- Steps to reproduce - Exact steps to trigger the issue
- Expected behavior - What should happen
- Actual behavior - What actually happens
- Environment - VS Code version, OS, neo-git-graph version
- Screenshots - If applicable
Example Issue Report
Example Issue Report
Title: Graph doesn’t update after committing through terminalDescription:When I make a commit using
git commit in the integrated terminal, the Git Graph view doesn’t automatically refresh to show the new commit.Steps to reproduce:- Open Git Graph on a repository
- Make changes to a file
- In terminal, run
git add .andgit commit -m "test" - Check Git Graph - commit doesn’t appear
- VS Code: 1.98.0
- neo-git-graph: 0.1.1
- OS: macOS 14.2
Feature Requests
Have an idea? Open a feature request. Describe:- Use case - What problem does this solve?
- Proposed solution - How should it work?
- Alternatives - Any other approaches considered?
- Examples - How do other tools handle this?
License
By contributing to neo-git-graph, you agree that your contributions will be licensed under the MIT License. This is important! The entire project is MIT licensed to preserve the open-source nature of the original Git Graph (before its license change in May 2019).All contributions must be your original work or properly attributed. Don’t submit code copied from the non-MIT versions of Git Graph or other incompatibly-licensed sources.
Questions?
Not sure about something? Feel free to:- Open a discussion on GitHub
- Comment on an existing issue
- Ask in your pull request