Here's a basic template for your CONTRIBUTING.md
file. This guide will help developers understand how to contribute to your project, covering everything from setting up the development environment to making a pull request.
Thank you for your interest in contributing to our project! We appreciate all types of contributions, from code improvements to bug reports and documentation updates. To make sure the process is smooth for everyone, please take a moment to review the following guidelines.
- Code of Conduct
- How to Contribute
- Development Environment Setup
- How to Report a Bug
- How to Suggest a Feature
- Submitting a Pull Request
- Style Guidelines
Please review our Code of Conduct to understand how we expect everyone to behave in the community.
You can contribute in several ways:
- Reporting bugs
- Suggesting features
- Improving documentation
- Writing or refactoring code
- Reviewing and testing pull requests
To contribute to the codebase, you need to set up your local development environment:
-
Fork the repository:
- Go to the repository on GitHub and click the Fork button.
-
Clone your fork:
git clone https://github.com/your-username/hijri-date-picker.git cd hijri-date-picker
-
Install dependencies:
- Ensure you have JDK 21 installed.
- For Android Studio users, import the project and sync the Gradle dependencies.
-
Run the project:
- For Android:
./gradlew assembleDebug
- For Android:
-
Create a new branch:
git checkout -b feature/your-feature-name
If you find a bug, please open an issue here. When reporting a bug, include:
- A clear and descriptive title.
- Steps to reproduce the issue.
- The expected result and what actually happens.
- The version of the app or library you are using.
- Any error logs or screenshots that might help diagnose the issue.
If you have an idea for a new feature or an improvement, open a feature request here and provide:
- A clear and descriptive title.
- A detailed explanation of the feature.
- How the feature would benefit the project.
- Any alternatives you’ve considered.
Before submitting your pull request (PR), make sure your changes follow these steps:
-
Fork and clone the repository (see the Development Setup).
-
Create a new branch for your changes:
git checkout -b feature/your-feature-name
-
Make your changes.
-
Write tests for any new features.
-
Commit your changes following the commit message guidelines.
-
Push your changes to your branch:
git push origin feature/your-feature-name
-
Submit a pull request:
- Go to the repository on GitHub and click New pull request.
- In the pull request description, explain what changes were made and why.
- Link any relevant issues (e.g.,
Closes #123
).
-
Wait for approval: Your pull request will be reviewed, and feedback might be provided. Once approved, it will be merged into the
main
branch.
We aim to keep the codebase consistent. Please follow these guidelines:
- Code formatting: Ensure code is clean and follows our coding style. We recommend using the built-in formatter in your IDE (Android Studio, IntelliJ).
- Kotlin guidelines: Follow Kotlin’s official style guide.
- Document your code: Add comments for complex logic or anything non-obvious.
- Write unit tests: If you are adding or modifying features, write unit tests to ensure everything works as expected.
- Format:
<type>(scope): <message>
. - Types:
feat
: New featurefix
: Bug fixdocs
: Documentation changesstyle
: Code style or formattingrefactor
: Code refactoringtest
: Adding or updating tests
Example:
git commit -m "feat(date-picker): add support for year range customization"
Thank you for your contributions and helping improve the project!