github.com/gojue/ecapture@v0.8.2/CONTRIBUTING.md (about) 1 # How to contribute 2 3 eCapture is AGPL-3.0 licensed and accepts contributions via GitHub pull requests. This document outlines some of the conventions on commit message formatting, contact points for developers, and other resources to help get contributions into eCapture. 4 5 [//]: # (# Email and chat) 6 7 ## Getting started 8 9 - Fork the repository on GitHub 10 - Read the [README.md](./README.md) for build instructions 11 12 ## Reporting bugs and creating issues 13 14 Reporting bugs is one of the best ways to contribute. However, a good bug report has some very specific qualities, so please read over our short document on [reporting bugs](.github/ISSUE_TEMPLATE/bug_report.md) before submitting a bug report. This document might contain links to known issues, another good reason to take a look there before reporting a bug. 15 16 ## Contribution flow 17 18 This is a rough outline of what a contributor's workflow looks like: 19 20 - Create a topic branch from where to base the contribution. This is usually main. 21 - Make commits of logical units. 22 - Make sure commit messages are in the proper format (see below). 23 - Push changes in a topic branch to a personal fork of the repository. 24 - Submit a pull request to gojue/ecapture. 25 26 [//]: # (- The PR must receive a LGTM from two maintainers found in the MAINTAINERS file.) 27 28 Thanks for contributing! 29 30 ### Code style 31 32 The coding style suggested by the Golang community is used in eCapture. See the [style doc](https://github.com/golang/go/wiki/CodeReviewComments) for details. 33 34 Please follow this style to make eCapture easy to review, maintain and develop. 35 36 ### Format of the commit message 37 38 We follow a rough convention for commit messages that is designed to answer two 39 questions: what changed and why. The subject line should feature the what and 40 the body of the commit should describe the why. 41 42 ``` 43 cli: update module name "mysqld56" to "mysqld" . 44 45 add shortflag for "debug" flag. 46 47 Fixes #6 48 ``` 49 50 The format can be described more formally as follows: 51 52 ``` 53 <package>: <what changed> 54 <BLANK LINE> 55 <why this change was made> 56 <BLANK LINE> 57 <footer> 58 ``` 59 60 The first line is the subject and should be no longer than 70 characters, the second 61 line is always blank, and other lines should be wrapped at 80 characters. This allows 62 the message to be easier to read on GitHub as well as in various git tools. 63 64 ### Pull request across multiple files and packages 65 66 If multiple files in a package are changed in a pull request for example: 67 68 ``` 69 user/config.go 70 user/const.go 71 ``` 72 73 At the end of the review process if multiple commits exist for a single package they 74 should be squashed/rebased into a single commit before being merged. 75 76 ``` 77 user: <what changed> 78 [..] 79 ``` 80 81 If a pull request spans many packages these commits should be squashed/rebased into a single 82 commit using message with a more generic `*:` prefix. 83 84 ``` 85 *: <what changed> 86 [..] 87 ```