OCamlPro/ocp-indent — pull request #56 by def-lkb (2013-03-29 10:35:56+00:00)
Title: "Inline mode" to ease integration with editors (currently vim mode)

The following patch adds an "inline" mode, in which ocp-indent read input line by line:
− the line read is unescaped, "\\\\" are replaced by '\\' and "\\n" by '\n',
− indentation is done as if this expansion was the complete file,
− indented result is written using the same escaping scheme, and flushed line by line.

This allow an easy and efficient interactive integration of ocp-indent inside vim, providing a "near-tuareg" edition quality (the other option being spawning one or more process for each line during interactive edition).

I would be very grateful if this or a similar feature could be implemented in the officiel distribution, thanks!