Thank you for your interest in contributing to Copybuffer! This project is primarily for personal use, but contributions are welcome.
- Node.js 18 or higher
- npm
- Ubuntu/Linux (for full clipboard and hotkey support)
- Git
-
Fork the repository
-
Clone your fork:
git clone https://github.com/YOUR_USERNAME/Copybuffer.git cd Copybuffer -
Install dependencies:
npm install
-
Build the project:
npm run build
Copybuffer/
├── src/
│ ├── clipboard/ # Clipboard monitoring logic
│ ├── config/ # Configuration management
│ ├── hotkeys/ # Global hotkey handling
│ ├── search/ # Search functionality
│ ├── storage/ # JSON file storage
│ ├── sync/ # GitHub Gist sync
│ ├── cli.ts # CLI interface
│ ├── index.ts # Main entry point
│ ├── types.ts # TypeScript type definitions
│ └── exports.ts # Public API exports
├── dist/ # Compiled JavaScript (gitignored)
├── package.json # Project configuration
├── tsconfig.json # TypeScript configuration
└── README.md # Documentation
-
Create a new branch:
git checkout -b feature/your-feature-name
-
Make your changes in the
src/directory -
Build and test:
npm run build npm run lint
-
Test your changes:
# Test CLI commands node dist/cli.js --help node dist/cli.js list # Run the demo ./demo.sh
- Follow existing code style
- Use TypeScript for all new code
- Run linter before committing:
npm run lint
- Format code with Prettier:
npm run format
Use clear, descriptive commit messages:
Add feature: Brief description
Detailed explanation of what changed and why.
Examples:
Add clipboard image supportFix: Handle empty clipboard gracefullyDocs: Update installation instructions
Currently, the project uses manual testing. To test your changes:
-
Build the project:
npm run build
-
Test CLI commands:
node dist/cli.js config node dist/cli.js list node dist/cli.js search "test" -
Test monitoring (in a safe environment):
node dist/cli.js start # Copy some text # Ctrl+C to stop node dist/cli.js list
-
Run the demo script:
./demo.sh
-
Ensure your code builds without errors:
npm run build npm run lint
-
Update documentation if needed:
- README.md for user-facing changes
- EXAMPLES.md for new features
- Code comments for complex logic
-
Create a pull request with:
- Clear title describing the change
- Detailed description of what and why
- Any related issues referenced
-
Wait for review and address feedback
- Cross-platform support (macOS, Windows)
- Automated tests
- Better hotkey support with modifier keys
- Clipboard image/file support
- GUI interface
- Encrypted clipboard entries
- Plugin system
- Advanced search filters
- More usage examples
- Video tutorials
- Troubleshooting guides
- API documentation
- Open an issue for bugs or feature requests
- Check existing issues before creating new ones
- Provide detailed information:
- OS and version
- Node.js version
- Steps to reproduce (for bugs)
- Expected vs actual behavior
- Treat everyone with respect
- Be constructive in feedback
- Focus on the code, not the person
- Help others learn
- Share knowledge
- Welcome newcomers
- Use inclusive language
- Stay on topic
- Keep discussions productive
By contributing to Copybuffer, you agree that your contributions will be licensed under the MIT License.
Your contributions help make Copybuffer better for everyone!