Function

Ggitmessage_prettify

Declaration [src]

gchar*
ggit_message_prettify (
  const gchar* message,
  gboolean strip_comments,
  gchar comment_char
)

Description [src]

Prettify a commit message by removing excess whitespace and making sure the last line ends with a newline. If strip_comments is TRUE, then lines starting with a comment_char will be removed.

Parameters

message const gchar*
 

The message.

 The data is owned by the caller of the function.
 The value is a NUL terminated UTF-8 string.
strip_comments gboolean
 

Whether to strip comments.

comment_char gchar
 

Comment character.

Return value

Returns: gchar*
 

The prettified message.

 The caller of the function takes ownership of the data, and is responsible for freeing it.
 The value is a NUL terminated UTF-8 string.