2

How to reuse past commit's message while pushing new commit to the branch so that both subject and the description are retained?
When I am typing
git commit --reuse-message=<commit_ID || commit_ref> or
git commit --reedit-message=<commit_ID || commit_ref> , whether I'd like to just copy-paste the message or edit it first, I am getting the message subject only.
Any suggestions? In advance, thx!

Marek Bocian
  • 115
  • 10
  • 1
    `whether I'd like to just copy-paste the message or edit it first, I am getting the message subject only.` ? What you mean by this ? – Rmahajan Dec 19 '19 at 13:36
  • What is the difference between the "subject" and "description" of a commit message? From Git's point of view, the commit message is a single logical thing. – Tim Biegeleisen Dec 19 '19 at 13:36
  • 1
    Does this answer your question? [Is there a way to reuse the previous comment on a git commit?](https://stackoverflow.com/questions/18429086/is-there-a-way-to-reuse-the-previous-comment-on-a-git-commit) – stud3nt Dec 19 '19 at 13:36
  • 1
    @TimBiegeleisen, subject is first line and description is remainder – EncryptedWatermelon Dec 19 '19 at 13:37
  • 1
    Turns out that commands that I provided above indeed fetch the whole message of the indicated commit. Consequently, the question duplicates the one linked by @stud3nt Thank you all for the help. Greetings! – Marek Bocian Dec 19 '19 at 15:15

0 Answers0