LogoLogo
MainsailMainsailOSCrowsnest
  • Welcome to Mainsail
  • Setup
    • Installation
      • MainsailOS
      • KIAUH
      • Docker
      • Manual setup
      • my.mainsail.xyz
    • Updates
      • Update Manager
      • Manual Update
    • Configuration
  • overview
    • Features
      • Bed Mesh
      • Console
      • Dashboard Organisation
      • Exclude Objects
      • Hide macros, outputs or fans
      • Localization
      • Macro Management
      • Macro Prompts
      • Presets
      • Print History and Statistics
      • Query devices
      • Built-in Themes
      • Custom Themes
        • Prepare
        • Backgrounds
        • Logos and Icons
        • Custom Navigation
        • Custom CSS
        • Community Themes
      • Thumbnails
      • Webcam
    • Settings
      • General
      • Console
      • Control
      • Dashboard
      • Editor
      • G-Code Viewer
      • Macros
      • Presets
      • Printers
      • UI-Settings
      • Webcams
    • Slicer
      • Cura
      • Ideamaker
      • PrusaSlicer
      • SuperSlicer
    • Quicktips
      • Slicer upload
      • Remote Access
      • Printer power switch
      • Additional Sensors
      • Disable Octoprint LCD menu
      • config.json
  • FAQ
    • Mainsail
    • Klipper warnings
      • Deprecated Values
      • Deprecated Options
      • Runtime Warning
    • Moonraker warnings
      • PolicyKit Permissions
    • Klipper errors
      • MCU Protocol error
    • Mainsail errors
      • Unauthorized
    • Getting Help
      • Discord
      • GitHub Discussions
  • About
    • Data Privacy
    • Sponsors
    • Development
      • Code standards
      • Contribute
      • Environment
      • Localization
    • Credits
  • 🔗Links
    • Github
    • Release Notes
    • Discord
    • Youtube
Powered by GitBook
On this page
  • Familiarize Yourself with the Code Standards
  • Fork and Clone the Repository
  • Create a New Branch
  • Make Your Changes
  • Commit Your Changes
  • Push Your Branch to GitHub
  • Create a Pull Request
  • Respond to Feedback
  • Celebrate Your Contribution!

Was this helpful?

Edit on GitHub
  1. About
  2. Development

Contribute

We welcome contributions to Mainsail! Whether fixing bugs, adding features, or improving documentation, your help is invaluable. Please follow these guidelines to ensure a smooth process.

PreviousCode standardsNextEnvironment

Last updated 9 months ago

Was this helpful?

Familiarize Yourself with the Code Standards

Before contributing, make sure to review the Mainsail . Adhering to these standards helps maintain code quality and consistency across the project. Key areas include:

  • Coding Style: Follow the project's conventions for formatting and structure.

  • Commit Messages: Write clear and concise commit messages that describe the changes you've made.

  • Documentation: Ensure that your code is well-documented, and update any relevant sections of the project documentation.

Fork and Clone the Repository

If you haven't already, fork the Mainsail repository on GitHub to create a personal copy of the project. Then, clone your fork to your local machine:

git clone https://github.com/YOUR-GITHUB-USERNAME/mainsail.git
cd mainsail

If you need help to setup your Environment, please follow this .

Create a New Branch

Always create a new branch for your work rather than making changes directly on the main branch. Use a descriptive name for your branch that reflects the work you're doing:

git checkout -b your-feature-branch

Make Your Changes

Implement your changes while following the Mainsail code standards. Be sure to test your changes thoroughly in your local development environment.

Commit Your Changes

Once your changes are ready, stage and commit them to your branch. Use meaningful commit messages:

git add .
git commit -m "Description of the changes made"

git commit -m "feat: add new user login feature"

Following this format ensures that our commit history is clear and organized, which helps with tracking changes and generating release notes.

Push Your Branch to GitHub

After committing your changes, push your branch to your GitHub fork:

git push origin your-feature-branch

Create a Pull Request

Once your branch is pushed, go to the Mainsail repository on GitHub and open a Pull Request (PR) from your branch. In your PR description, include the following:

  • Problem Description: Clearly describe the issue or feature your PR addresses.

  • Solution Overview: Provide an overview of the changes you made and why.

  • How to Test: Include detailed instructions on how to test your changes.

  • Screenshots: Upload screenshots or gifs to demonstrate the feature or fix, especially for UI changes.

  • Link to Issues: If your PR resolves a specific issue, mention it by linking to the issue.

Respond to Feedback

Mainsail maintainers will review your PR. Be prepared to make adjustments based on feedback. Once approved, your changes will be merged into the main project.

Celebrate Your Contribution!

After your PR is merged, your contributions become part of Mainsail. Thank you for helping to improve the project!

We follow the specification for writing commit messages. This means your commit message should start with a type (like feat, fix, or docs), followed by a short, descriptive summary of the change. For example:

PR Title: Ensure that your PR title follows the schema. Since we use squash and merge, the PR title will become the commit message in the Mainsail commit history.

Code Standards
guide
Conventional Commits
Conventional Commits