caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Adrien Nader <adrien@notk.org>
To: Francois Berenger <berenger@riken.jp>
Cc: caml users <caml-list@inria.fr>
Subject: Re: [Caml-list] long lines in some OCaml code
Date: Thu, 3 Oct 2013 09:07:32 +0200	[thread overview]
Message-ID: <20131003070732.GA1830@notk.org> (raw)
In-Reply-To: <524D15AE.3050600@riken.jp>

Hi,

On Thu, Oct 03, 2013, Francois Berenger wrote:
> Is there a way to automatically cut all long lines
> in a code base (and indent the cut part correctly)?

That's something I never do automatically on whole files for fear of
making huge and ugly diffs but instead with vim's "gq<movement>"
command. It works well except for strings that end up spanning lines
(but that's a matter of vim configuration :) ).

If you want to do it on whole files (with a commit that only does
reformatting :) ), you might want to look at ocp-indent[1].

[1] http://www.typerex.org/ocp-indent.html
-- 
Adrien Nader

  reply	other threads:[~2013-10-03  7:07 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-03  6:58 Francois Berenger
2013-10-03  7:07 ` Adrien Nader [this message]
2013-10-03  7:09   ` David House
2013-10-03  8:09 ` Lukasz Stafiniak

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20131003070732.GA1830@notk.org \
    --to=adrien@notk.org \
    --cc=berenger@riken.jp \
    --cc=caml-list@inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).