|
| 1 | +# Contributing to UNT Robotics Website |
| 2 | + |
| 3 | +Thank you for considering contributing to the UNT Robotics website! This document provides guidelines and instructions for contributing to the project. |
| 4 | + |
| 5 | +## Code of Conduct |
| 6 | + |
| 7 | +All contributors are expected to adhere to our code of conduct: |
| 8 | + |
| 9 | +1. Be respectful and inclusive of all contributors |
| 10 | +2. Follow UNT's academic integrity policies |
| 11 | +3. Maintain professionalism in communications |
| 12 | +4. Report any inappropriate behavior to project maintainers |
| 13 | + |
| 14 | +## Getting Started |
| 15 | + |
| 16 | +1. Fork the repository |
| 17 | +2. Clone your fork locally |
| 18 | +3. Set up your development environment (see GETTING_STARTED.md) |
| 19 | +4. Create a new branch for your feature/fix |
| 20 | +5. Make your changes |
| 21 | +6. Submit a pull request |
| 22 | + |
| 23 | +## Development Workflow |
| 24 | + |
| 25 | +### 1. Branching Strategy |
| 26 | + |
| 27 | +- `main` - Production branch |
| 28 | +- `develop` - Development branch |
| 29 | +- Feature branches: `feature/your-feature-name` |
| 30 | +- Bugfix branches: `fix/bug-description` |
| 31 | + |
| 32 | +### 2. Commit Messages |
| 33 | + |
| 34 | +Follow conventional commits format: |
| 35 | + |
| 36 | +``` |
| 37 | +type(scope): description |
| 38 | +
|
| 39 | +[optional body] |
| 40 | +
|
| 41 | +[optional footer] |
| 42 | +``` |
| 43 | + |
| 44 | +Types: |
| 45 | + |
| 46 | +- `feat`: New feature |
| 47 | +- `fix`: Bug fix |
| 48 | +- `docs`: Documentation changes |
| 49 | +- `style`: Code style changes |
| 50 | +- `refactor`: Code refactoring |
| 51 | +- `test`: Adding/modifying tests |
| 52 | +- `chore`: Maintenance tasks |
| 53 | + |
| 54 | +Example: |
| 55 | + |
| 56 | +``` |
| 57 | +feat(merchandise): add size selection to t-shirt orders |
| 58 | +
|
| 59 | +- Added size dropdown component |
| 60 | +- Integrated with Printful API |
| 61 | +- Updated order processing logic |
| 62 | +
|
| 63 | +Closes #123 |
| 64 | +``` |
| 65 | + |
| 66 | +### 3. Pull Request Process |
| 67 | + |
| 68 | +1. Update documentation for any new features |
| 69 | +2. Add/update tests as needed |
| 70 | +3. Ensure all tests pass |
| 71 | +4. Update CHANGELOG.md |
| 72 | +5. Request review from maintainers |
| 73 | +6. Address review feedback |
| 74 | + |
| 75 | +### 4. Code Style Guidelines |
| 76 | + |
| 77 | +#### PHP |
| 78 | + |
| 79 | +- Follow PSR-12 coding standards |
| 80 | +- Use type hints where possible |
| 81 | +- Document classes and methods with PHPDoc |
| 82 | + |
| 83 | +```php |
| 84 | +/** |
| 85 | + * Process a new merchandise order |
| 86 | + * |
| 87 | + * @param int $orderId Order identifier |
| 88 | + * @param array $items List of ordered items |
| 89 | + * @return bool Success status |
| 90 | + */ |
| 91 | +public function processOrder(int $orderId, array $items): bool |
| 92 | +``` |
| 93 | + |
| 94 | +#### JavaScript |
| 95 | + |
| 96 | +- Use ES6+ features |
| 97 | +- Follow Airbnb JavaScript Style Guide |
| 98 | +- Document functions with JSDoc |
| 99 | + |
| 100 | +```javascript |
| 101 | +/** |
| 102 | + * Updates the shopping cart total |
| 103 | + * @param {Array} items - Cart items |
| 104 | + * @returns {number} Cart total |
| 105 | + */ |
| 106 | +function updateCartTotal(items) { |
| 107 | +``` |
| 108 | +
|
| 109 | +#### HTML/CSS |
| 110 | +
|
| 111 | +- Use semantic HTML5 elements |
| 112 | +- Follow BEM naming convention for CSS |
| 113 | +- Maintain responsive design principles |
| 114 | +
|
| 115 | +### 5. Testing Guidelines |
| 116 | +
|
| 117 | +1. **Unit Tests** |
| 118 | +
|
| 119 | + - Write tests for new features |
| 120 | + - Update existing tests when modifying functionality |
| 121 | + - Aim for high coverage of critical paths |
| 122 | +
|
| 123 | +2. **Integration Tests** |
| 124 | +
|
| 125 | + - Test PayPal integration using sandbox |
| 126 | + - Test Discord bot functionality in test server |
| 127 | + - Verify email notifications |
| 128 | +
|
| 129 | +3. **Manual Testing** |
| 130 | + - Test on multiple browsers |
| 131 | + - Verify mobile responsiveness |
| 132 | + - Check accessibility compliance |
| 133 | +
|
| 134 | +### 6. Documentation |
| 135 | +
|
| 136 | +1. **Code Documentation** |
| 137 | +
|
| 138 | + - Document complex logic |
| 139 | + - Explain non-obvious decisions |
| 140 | + - Keep documentation up to date |
| 141 | +
|
| 142 | +2. **API Documentation** |
| 143 | +
|
| 144 | + - Document new endpoints |
| 145 | + - Include request/response examples |
| 146 | + - Note any authentication requirements |
| 147 | +
|
| 148 | +3. **User Documentation** |
| 149 | + - Update user guides for new features |
| 150 | + - Include screenshots where helpful |
| 151 | + - Document configuration changes |
| 152 | +
|
| 153 | +## Areas for Contribution |
| 154 | +
|
| 155 | +1. **High Priority** |
| 156 | +
|
| 157 | + - Payment processing improvements |
| 158 | + - Discord integration enhancements |
| 159 | + - Security updates |
| 160 | + - Performance optimization |
| 161 | +
|
| 162 | +2. **Feature Requests** |
| 163 | +
|
| 164 | + - Event management system |
| 165 | + - Member dashboard improvements |
| 166 | + - Automated testing |
| 167 | + - Analytics integration |
| 168 | +
|
| 169 | +3. **Documentation** |
| 170 | + - API documentation |
| 171 | + - Setup guides |
| 172 | + - User documentation |
| 173 | + - Code comments |
| 174 | +
|
| 175 | +## Getting Help |
| 176 | +
|
| 177 | +- Join our [Discord server](https://discord.gg/untrobotics) |
| 178 | +- Check our [Jira board](https://untrobotics.atlassian.net) |
| 179 | +- Check existing issues and discussions |
| 180 | +- Contact project maintainers |
| 181 | +- Review documentation |
| 182 | +
|
| 183 | +## Project Management |
| 184 | +
|
| 185 | +We use Jira to track our development work. You can find our project board at [untrobotics.atlassian.net](https://untrobotics.atlassian.net). |
| 186 | +
|
| 187 | +1. **Creating Issues** |
| 188 | +
|
| 189 | + - Check existing issues first |
| 190 | + - Use provided templates when available |
| 191 | + - Include clear reproduction steps for bugs |
| 192 | + - Tag appropriate components |
| 193 | +
|
| 194 | +2. **Working with Jira** |
| 195 | + - Assign yourself to issues you're working on |
| 196 | + - Update issue status as you progress |
| 197 | + - Link pull requests to issues |
| 198 | + - Add time tracking if applicable |
| 199 | +
|
| 200 | +## Security Issues |
| 201 | +
|
| 202 | +For security issues: |
| 203 | +
|
| 204 | +1. **DO NOT** create a public issue |
| 205 | +2. Email webmaster@untrobotics.com |
| 206 | +3. Include detailed description |
| 207 | +4. Wait for confirmation before disclosure |
| 208 | +
|
| 209 | +## License |
| 210 | +
|
| 211 | +By contributing, you agree that your contributions will be licensed under the project's license. |
| 212 | +
|
| 213 | +## Questions? |
| 214 | +
|
| 215 | +If you have questions about contributing: |
| 216 | +
|
| 217 | +1. Check existing documentation |
| 218 | +2. Search closed issues |
| 219 | +3. Ask in Discord |
| 220 | +4. Contact maintainers |
| 221 | +
|
| 222 | +Thank you for contributing to UNT Robotics! |
0 commit comments