Thank you for your interest in contributing to wgpu!
- Fork the repository
- Clone your fork:
git clone https://github.com/YOUR_USERNAME/wgpu - Create a branch:
git checkout -b feat/your-feature - Make your changes
- Run tests:
go test ./... - Commit:
git commit -m "feat: add your feature" - Push:
git push origin feat/your-feature - Open a Pull Request
# Clone the repository
git clone https://github.com/gogpu/wgpu
cd wgpu
# Install dependencies
go mod download
# Run tests
go test ./...
# Run linter
golangci-lint run- Follow standard Go conventions
- Use
gofmtfor formatting - Use
golangci-lintfor linting - Write tests for new functionality
- Document public APIs
wgpu/
├── types/ # WebGPU type definitions
├── core/ # Core validation and state tracking
├── hal/ # Hardware abstraction layer
│ ├── vulkan/ # Vulkan backend
│ ├── metal/ # Metal backend
│ ├── dx12/ # DirectX 12 backend
│ └── gl/ # OpenGL backend
├── internal/ # Internal utilities
└── cmd/ # CLI tools (if any)
We use Conventional Commits:
feat(component): add new feature
fix(component): fix bug
docs: update documentation
test: add tests
refactor: code refactoring
chore: maintenance tasks
Components: types, core, hal, vulkan, metal, dx12, gl, docs, ci
- Keep PRs focused on a single change
- Update documentation if needed
- Add tests for new features
- Ensure all tests pass
- Reference related issues
go test ./...go test -cover ./...go test -race ./...- Use GitHub Issues
- Include Go version and OS
- Provide minimal reproduction
- Include error messages
Open a GitHub Discussion or reach out to maintainers.
Thank you for contributing!