From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by sympa.inria.fr (Postfix) with ESMTPS id C72D17EF10 for ; Tue, 24 Feb 2015 18:57:59 +0100 (CET) X-IronPort-AV: E=Sophos;i="5.09,639,1418079600"; d="scan'208";a="101187291" Received: from meleze.ens.fr (HELO [129.199.99.114]) ([129.199.99.114]) by mail3-relais-sop.national.inria.fr with ESMTP/TLS/DHE-RSA-AES128-SHA; 24 Feb 2015 18:57:56 +0100 Message-ID: <54ECBBA4.9030405@inria.fr> Date: Tue, 24 Feb 2015 18:57:56 +0100 From: Francois Berenger User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 MIME-Version: 1.0 To: OCaml Mailing List Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Subject: [Caml-list] indenting a .ml file with emacs in batch mode using ocaml-mode style Hello, Is there anyone who knows how to tell emacs how to indent a given .ml file using the indentation style from ocaml-mode? It should ressemble something like this: emacs -batch source.ml \ --eval '(indent-region (point-min) (point-max) nil)' \ -f save-buffer I just don't know how to tell emacs to use the ocaml-mode for that instead of whatever the user has configured in his ~/.emacs (for example, instead of tuareg-mode). Thanks a lot, Francois.