Thanks for your interest in contributing to cc-clip!
git clone https://github.com/ShunmeiCho/cc-clip.git
cd cc-clip
make build
make testRequirements: Go 1.21+, pngpaste (macOS, brew install pngpaste)
Project structure:
cmd/cc-clip/— CLI entry pointinternal/daemon/— Local clipboard HTTP serverinternal/tunnel/— Client for fetching through SSH tunnelinternal/shim/— Bash shim templates and remote deploymentinternal/token/— Session token managementinternal/exitcode/— Segmented exit codesinternal/doctor/— Diagnostic checks
Commands:
make build # Build binary
make test # Run all tests
make vet # Run go vet
make release-local # Cross-compile for local testing only (NOT for GitHub releases)Warning:
make release-localproduces bare binaries with different naming than goreleaser. Never upload these to GitHub Releases — the install script will 404. Production releases are automated via GitHub Actions on tag push. See CLAUDE.md.
Open an issue with:
- cc-clip version (
cc-clip version) - Local OS and remote OS/arch
- Steps to reproduce
- Output of
cc-clip doctor --host <your-host>(redact sensitive info) - Shim debug logs:
CC_CLIP_DEBUG=1 xclip -selection clipboard -t TARGETS -o
Open an issue describing the use case and proposed solution.
- Fork the repo and create a feature branch
- Write tests for new functionality
- Ensure
make testandmake vetpass - Use conventional commit messages:
feat:,fix:,refactor:,docs:,test: - Keep PRs focused — one feature or fix per PR
- Follow standard Go conventions (
gofmt,go vet) - Keep files under 400 lines where possible
- Prefer immutability — create new objects rather than mutating
- Add comments for non-obvious logic
Some changes require updates across multiple files. See CLAUDE.md for the full list:
- New API endpoint →
daemon/server.go+tunnel/fetch.go+shim/template.go - New exit code →
exitcode/exitcode.go+cmd/cc-clip/main.go+ shim templates - Token format change →
token/token.go+ shim templates
By contributing, you agree that your contributions will be licensed under the MIT License.