Module gix_filter::eol

source ·
Expand description

convert line endings in buffers

Modules§

Structs§

  • Git Configuration that affects how CRLF conversions are applied.
  • Statistics about a buffer that helps to safely perform EOL conversions

Enums§

  • The combination of crlf, text and eol attributes into one neat package.
  • Possible states for the core.autocrlf.
  • The kind of end of lines to set.

Functions§

  • Given a src buffer, change it git (\n) line endings and store the result in buf. Return true if buf was written or false if nothing had to be done. Depending on the state in buf, index_object is called to write the version of src as stored in the index into the buffer and if it is a blob, or return Ok(None) if no such object exists. If renormalization is desired, let it return Ok(None) at all times to not let it have any influence over the outcome of this function. If round_trip_check is not None, round-tripping will be validated and handled accordingly.
  • Convert all \n in src to crlf if digest and config indicate it, returning true if buf holds the result, or false if no change was made after all.