-
Notifications
You must be signed in to change notification settings - Fork 824
Description
Improving the CONTRIBUTING.md file for mruby/mruby is crucial for attracting and retaining contributors. A clear, concise, and friendly guide makes it easier for newcomers to get involved.
10 Suggestions for Improving the mruby/mruby CONTRIBUTING.md
Here are 10 suggestions to enhance the mruby/mruby repository's CONTRIBUTING.md file:
1. Start with a Welcoming Tone and Mission Statement
Begin with a warm greeting that encourages participation. Briefly state the purpose of mruby and why contributions are valued.
- Suggestion: "Welcome! We're thrilled you're considering contributing to mruby. Your contributions, big or small, are vital to improving this lightweight Ruby implementation. This guide will help you get started."
- Why: Sets a positive tone and makes contributors feel appreciated from the outset.
2. Clearly Define "How to Contribute" Categories
Break down contributions into distinct types. This helps potential contributors find their niche.
- Suggestion: Use clear headings like:
- Reporting Bugs
- Suggesting Enhancements/Features
- Writing Code (Bug Fixes, New Features, Optimizations)
- Improving Documentation
- Testing and Reviewing
- Why: Provides a quick overview of how one can help, catering to different skill sets.
3. Detailed "Getting Started with Development" Section
Provide a step-by-step guide for setting up a development environment.
- Suggestion:
- Prerequisites (e.g., C compiler,
make,git). - Cloning the repository.
- Building mruby locally.
- Running tests.
- (Optional but helpful) Basic IDE setup advice if common patterns exist.
- Prerequisites (e.g., C compiler,
- Why: Reduces friction for new developers, allowing them to quickly get to a state where they can contribute code.
4. Comprehensive Guide for Reporting Bugs
Ensure bug reports are useful and actionable.
- Suggestion:
- Check existing issues: "Before opening a new issue, please search mruby's issue tracker to see if the bug has already been reported."
- Provide a Minimal Reproducible Example (MRE): Emphasize the importance of small, self-contained code snippets that demonstrate the bug.
- Environment details: Request compiler version, OS, mruby commit hash, etc.
- Expected vs. Actual behavior: Clearly state what should happen and what does happen.
- Why: High-quality bug reports are essential for efficient debugging and resolution.
5. Clear Pull Request (PR) Guidelines
Set expectations for code contributions to streamline the review process.
- Suggestion:
- Forking and Branching: Explain the standard
fork -> branch -> PRworkflow. Suggest clear branch naming conventions (e.g.,feature/my-new-feature,bugfix/issue-123). - Commit Messages: Recommend a standard for commit messages (e.g., Conventional Commits or a simple
type: descriptionformat). - Coding Style: Link to or briefly outline
mruby's coding style guidelines (e.g., C code formatting, Ruby style if applicable for tests/tools). - Testing: Emphasize the need for new or updated tests to cover changes.
- PR Description: Request a clear description of the change, why it's needed, and reference any related issues.
- Forking and Branching: Explain the standard
- Why: Ensures consistency in contributions and speeds up code reviews.
6. Guidance on Writing Tests
mruby has a robust testing framework. Guide contributors on how to use it.
- Suggestion:
- Briefly explain where tests reside (
test/directory). - How to write a new test case (e.g., using
mrbtest). - How to run all tests or specific tests (
make test). - Emphasize that new features must come with tests, and bug fixes should include regression tests.
- Briefly explain where tests reside (
- Why: Good tests are crucial for maintaining code quality and preventing regressions.
7. Link to "Good First Issues" and Community Channels
Help newcomers find manageable tasks and connect with the community.
- Suggestion:
- Good First Issues: Provide a direct link to a filtered view of issues suitable for new contributors (e.g., "Good First Issue" label on GitHub/Jira).
- Community: Link to relevant mailing lists, Discord, or Gitter channels for discussions and questions.
- Why: Lowers the barrier for initial contributions and fosters community interaction.
8. Licensing and DCO (Developer Certificate of Origin) Information
Make legal requirements clear upfront.
- Suggestion:
- State that contributions are under the MIT License (or whichever
mrubyuses for contributions). - Explain the Developer Certificate of Origin (DCO) requirement, if applicable (common in Apache projects, though
mrubyis MIT). Provide instructions on how togit commit -s.
- State that contributions are under the MIT License (or whichever
- Why: Ensures legal compliance and protects both contributors and the project.
9. Documentation Contribution Guidelines
Documentation is just as important as code.
- Suggestion:
- Where documentation resides (e.g.,
doc/directory, README, source comments). - Preferred format (e.g., Markdown, RDoc).
- How to submit documentation changes via PR.
- Where documentation resides (e.g.,
- Why: Encourages improvements to user guides, API docs, and examples, which are vital for usability.
10. Code of Conduct Link
Ensure a respectful and inclusive environment for all contributors.
- Suggestion: Include a clear statement and a prominent link to the project's Code of Conduct.
- Why: Promotes a positive and safe community environment.