Overview
Conventional commit is a standardized method of writing commit messages in software development, aimed at making commit messages more readable, understandable, and manageable. The Conventional Commit specification recommends that a commit message should consist of three main parts:
- Type: Specifies the type of change made (e.g., fix, feat, docs, style, refactor, test, chore).
- Scope (optional): Specifies the part of the system that is affected by the change.
- Description: A brief description of the change made.
By adhering to the Conventional Commit standard, developers can write clear and concise commit messages that make it easier for others to understand what changes have been made to the codebase.
Here is an example of a commit message using the Conventional Commit standard:
feat(login): add forgot password feature
In this commit message:
feat
is the type of change, which stands for "feature". This indicates that a new feature has been added.login
is the scope of the change, which indicates the part of the system that has been affected. In this case, the login feature has been modified.add forgot password feature
is the description of the change, which briefly describes what has been added.
This is just the basic example, there are some more detailed rules that will be discussed in the next part.