Thank you for your interest in contributing to RAIDmgmt! Here are some guidelines to help you get started.
Be respectful and constructive in all interactions. We expect contributors to communicate professionally, provide helpful feedback, and work collaboratively toward the shared goals of the project.
- Fork the repository and clone your fork.
- Make sure you have Go 1.25+ and golangci-lint installed.
- Run
make allto verify that linting and tests pass before making changes.
- Create a branch for your work.
- Keep commits focused -- one logical change per commit.
- Follow the existing code style. The project uses
golangci-lintwith the configuration in.golangci.yaml. - Add or update tests for any changed behavior.
- Run
make allbefore submitting your changes.
- All new code must have accompanying unit tests.
- Tests should go in
_test.gofiles alongside the code they test. - Use testdata fixtures for CLI output parsing tests (see
pkg/implementation/raidcontroller/megaraid/testdata/for examples). - Run the full test suite with
make testsand ensure all tests pass. - Run
make lintto verify your code passes all linter checks.
- Update the README.md or DESIGN.md if your change affects the public API, architecture, or supported controllers.
- Document exported types and functions with Go doc comments.
- If adding a new adapter, document any limitations (unsupported operations) in DESIGN.md.
The library is designed to be extended with new controllers. To add one:
- Create a new package under
pkg/implementation/for any low-level CLI interactions (command runners, getters, managers). - Implement the port interfaces defined in
pkg/domain/ports/raidcontroller.go. If your controller does not support a given operation, returnports.ErrFunctionNotSupportedByImplementation. - Create a composite adapter under
pkg/implementation/raidcontroller/that wires the individual implementations together (seerhel8.goorsmartarray.gofor examples). - Add unit tests with testdata fixtures.
- Open a pull request against the
mainbranch. - Describe what your change does and why.
- Make sure CI checks pass (lint + tests).
- At least one maintainer review is required before merging.
Open a GitHub issue with a clear description of the problem or feature request. Include steps to reproduce if applicable.