Contributing to Super-Linter

We're thrilled that you'd like to contribute to this project. Your help is essential for keeping it great. Contributions of all kinds are welcome, from reporting bugs and suggesting features to submitting pull requests for code or documentation.

Submitting a Pull Request

We use pull requests to contribute new features, fixes, or documentation. To increase the likelihood of your pull request being accepted, please follow these guidelines:

  • Keep it focused: Submit separate pull requests for separate changes. If you are fixing a bug and adding a feature, they should be two different pull requests.
  • Write descriptive commit messages: Follow the Conventional Commits specification. This helps us automate changelogs and understand the purpose of your changes.
  • Update documentation: If you are adding a new feature or changing existing behavior, please update the relevant documentation (README.md, docs/, etc.).
  • Add tests: All new features and bug fixes should be accompanied by tests. Super-Linter's test suite is located in the test/ directory.

Development Environment Setup

The easiest way to get started with Super-Linter development is to use the provided Dev Container configuration for VS Code or GitHub Codespaces.

Using the Dev Container

  1. Ensure you have Docker and VS Code with the Dev Containers extension installed.
  2. When you open this repository in VS Code, you will be prompted to "Reopen in Container." Click it.
  3. This will build the Super-Linter Docker image and mount the necessary source files into the container, providing you with a ready-to-use development environment with all tools on the PATH.

Building and Testing Locally with Make

This project uses a Makefile to simplify common development tasks.

  1. Create a GitHub Personal Access Token: To pull dependencies during the build, you need a PAT. Store it in a file at the root of the repository:

    echo "YOUR_GITHUB_PAT" > .github-personal-access-token
  2. Build the Docker Image:

    make docker

    You can specify the image variant (standard or slim) with the IMAGE variable:

    make docker IMAGE=slim
  3. Run the Full Test Suite:

    make test
  4. Lint the Codebase:

    To run Super-Linter against its own source code:

    make lint-codebase
  5. Fix Codebase Issues:

    To apply automatic fixes for supported linters:

    make fix-codebase

For more advanced guides, such as adding a new linter, refer to the Advanced Guides.