Skip to content

body ​

Get the long "body" of the git commit message.

The returned message is the body of the commit, comprising everything but the first paragraph of the message. Leading and trailing whitespaces are trimmed.

Throws error if the summary is not valid utf-8.

Signature ​

ts
class Commit {
  body(): string | null;
}

Returns ​

  • null | string

    Long body of this commit message.

Errors ​

  • Error

    If the body is not valid utf-8.

Released under the MIT License.