File: multiple_projects.t

package info (click to toggle)
ocamlformat 0.28.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 14,436 kB
  • sloc: ml: 63,321; pascal: 4,769; lisp: 229; sh: 217; makefile: 121
file content (30 lines) | stat: -rw-r--r-- 891 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
First project formatted with the 'janestreet' profile:

  $ mkdir project1
  $ echo profile=janestreet > project1/.ocamlformat
  $ echo 'let _machin ?aaaaaaaaaa:_ ?bbbbbbbbbbb:_ ?cccccccccccc:_ ?ddddddddddddd:_ ?eeeeeeeeeeee:_ () = ()' > project1/main.ml

Second project formatted with the 'ocamlformat' profile:

  $ mkdir project2
  $ echo profile=ocamlformat > project2/.ocamlformat
  $ echo 'let _machin ?aaaaaaaaaa:_ ?bbbbbbbbbbb:_ ?cccccccccccc:_ ?ddddddddddddd:_ ?eeeeeeeeeeee:_ () = ()' > project2/main.ml

  $ ocamlformat -i project1/main.ml project2/main.ml

  $ cat project1/main.ml
  let _machin
        ?aaaaaaaaaa:_
        ?bbbbbbbbbbb:_
        ?cccccccccccc:_
        ?ddddddddddddd:_
        ?eeeeeeeeeeee:_
        ()
    =
    ()
  ;;

  $ cat project2/main.ml
  let _machin ?aaaaaaaaaa:_ ?bbbbbbbbbbb:_ ?cccccccccccc:_ ?ddddddddddddd:_
      ?eeeeeeeeeeee:_ () =
    ()