How to commit a change with both "message" and "description" with source control in MATLAB to github?

6 views (last 30 days)
If I push a change to github via the source control in MATLAB, I go to source control and view and commit changes. However, the window that opens has one comment section that fills both the ''message'' and ''description'' with the same information. I want that the ''message'' is short and the ''description'' is longer with an explanation. Is this possible via source control in MATLAB or only via git bash?

Accepted Answer

Suraj
Suraj on 27 Mar 2023
As per my understanding, you’d like to draft a comment that contains a message and description that is identified by GitHub.
You can do so in one of two ways –
1 .Using the Command-Line Git Client -
If you happen to use the CLI for Git in MATLAB, then simply use the following command:
!git commit -m “<title>” -m “<description>”
2 .Using the Source Control context menu –
In the dialog box that prompts you to enter a comment, use the following syntax to draft your commit message:
<Enter title here>
<Enter multiline description here>
Note: You must leave a blank line between your title and description.

More Answers (0)

Categories

Find more on Source Control in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!