Skip to content

Commit 6b3bf76

Browse files
marc0derclaude
andcommitted
docs: enhance contributing guide with industry standards
Co-Authored-By: Claude <[email protected]>
1 parent 4f3e7d9 commit 6b3bf76

File tree

1 file changed

+107
-8
lines changed

1 file changed

+107
-8
lines changed

CONTRIBUTING.md

Lines changed: 107 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,114 @@
1-
## Contributing
1+
# Contributing to SDKMAN! CLI
22

3-
We greatly value the feedback and contributions of our users.
3+
Thank you for your interest in contributing to SDKMAN! CLI. We greatly value the feedback and contributions of our users.
44

5-
We distinguish between Bugs/Issues, New Features and Support Requests. We also try to minimise the noise in our GitHub Issues stream and prefer having a conversation on [SDKMAN Discord](https://discord.gg/y9mVJYVyu4) before creating new issues if you are not entirely sure how to categorize your request. Sign up and join our Help channel.
5+
## Important Notice
66

7-
The [GitHub Issue Tracker](https://github.com/sdkman/sdkman-cli/issues/new) provides templates for required information.
7+
**This project is in maintenance mode.** We are only accepting bug fixes at this time, as SDKMAN! CLI is being rewritten in Rust. New features and enhancements will not be accepted.
88

9-
**Unfortunately, we might close any GitHub Issues that have not followed the requested template.**
9+
## Code of Conduct
1010

11-
### Pull Requests
11+
This project adheres to the [Contributor Covenant Code of Conduct](CODE_OF_CONDUCT.md). By participating, you are expected to uphold this code. Please report unacceptable behavior to [email protected].
1212

13-
Pull Requests are _always_ very welcome but require a valid GitHub Issue as described above. The PR template is to be filled in before submission, ensuring that it is _linked back_ to the GitHub Issue number by replacing `#XXX` with the appropriate issue reference.
13+
## How to Contribute
1414

15-
Each PR should also be accompanied by a passing test(s) proving its validity (where feasible). The feasibility of the test will emerge in the initial discussions of the issue.
15+
### Before You Start
16+
17+
We distinguish between:
18+
- **Bug Reports**: Issues with existing functionality
19+
- **Support Requests**: Questions about usage
20+
21+
We prefer to have a conversation on [SDKMAN Discord](https://discord.gg/y9mVJYVyu4) before creating new issues if you're unsure how to categorize your request. Join our Help channel to discuss.
22+
23+
### Reporting Bugs
24+
25+
1. **Search existing issues** to avoid duplicates
26+
2. **Use the issue template** when creating a new issue via our [GitHub Issue Tracker](https://github.com/sdkman/sdkman-cli/issues/new)
27+
3. **Provide detailed information** including:
28+
- Steps to reproduce the issue
29+
- Expected behavior
30+
- Actual behavior
31+
- Your environment (OS, shell, Java version)
32+
- Relevant logs or error messages
33+
34+
**Note:** Issues that don't follow the template may be closed.
35+
36+
### Submitting Pull Requests
37+
38+
Pull requests are always welcome but must follow these guidelines:
39+
40+
#### Prerequisites
41+
42+
1. **Link to an issue**: Every PR must reference a valid GitHub issue
43+
2. **Discuss first**: Talk about your proposed fix on Discord or in the issue before starting work
44+
3. **Keep it small**: Small, focused PRs are strongly preferred over large changes
45+
4. **Include tests**: Each PR should include passing tests that prove its validity (where feasible)
46+
47+
#### Development Setup
48+
49+
1. **Install required tools**:
50+
```bash
51+
sdk env install # Install JDK 11 from .sdkmanrc
52+
sdk env # Switch to correct SDK versions
53+
```
54+
55+
2. **Verify your setup**:
56+
```bash
57+
./gradlew test
58+
```
59+
60+
#### Development Workflow
61+
62+
1. **Fork the repository** and create a new branch from `master`
63+
2. **Make your changes** following our code standards
64+
3. **Write or update tests** to cover your changes
65+
4. **Run the test suite** to ensure everything passes:
66+
```bash
67+
./gradlew test
68+
```
69+
5. **Commit your changes** using clear, descriptive commit messages
70+
6. **Push to your fork** and submit a pull request
71+
72+
#### Pull Request Guidelines
73+
74+
- Fill in the PR template completely
75+
- Link back to the GitHub issue by replacing `#XXX` with the issue number
76+
- Ensure all tests pass
77+
- Keep commits focused and atomic
78+
- Write clear commit messages in imperative mood (e.g., "fix user login bug")
79+
- Be responsive to feedback during code review
80+
81+
#### Testing Requirements
82+
83+
- All bug fixes must include a test that would have caught the bug
84+
- Tests should follow the existing Cucumber BDD pattern
85+
- Tests should cover both happy path and edge cases
86+
- Run `./gradlew test` to verify all tests pass
87+
88+
### Code Standards
89+
90+
- Follow the existing code style in bash scripts
91+
- Use meaningful variable and function names
92+
- Add comments for complex logic
93+
- Avoid introducing new dependencies without discussion
94+
- Ensure backward compatibility
95+
96+
### Getting Help
97+
98+
- Join our [Discord server](https://discord.gg/y9mVJYVyu4) for questions
99+
- Check existing issues and discussions
100+
- Read the documentation in the repository
101+
102+
## Project Structure
103+
104+
- `src/main/bash/` - Core bash scripts implementing SDKMAN commands
105+
- `src/test/groovy/` - Groovy test code using Spock framework
106+
- `src/test/resources/features/` - Cucumber feature files (BDD tests)
107+
108+
## Recognition
109+
110+
Contributors will be recognized in our release notes and commit history. We appreciate your efforts to make SDKMAN! better!
111+
112+
## Questions?
113+
114+
If you have questions about contributing, feel free to ask on [Discord](https://discord.gg/y9mVJYVyu4) or open a discussion on GitHub.

0 commit comments

Comments
 (0)