We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 135f46a commit 10bf8caCopy full SHA for 10bf8ca
src/ocp-indent-gen-rules/main.ml
@@ -1,11 +1,15 @@
1
let exe_name = "ocp-indent-gen-rules"
2
3
let ignore = ref []
4
+let alias = ref "fmt"
5
6
let args =
7
[ ( "--ignore"
8
, Arg.String (fun s -> ignore := (String.split_on_char ',' s))
9
, "Comma separated list of files that should not be indented" )
10
+ ; ( "--alias"
11
+ , Arg.Set_string alias
12
+ , "The alias for the ocp-indent rules, default is fmt" )
13
]
14
15
let print_rules file =
@@ -21,7 +25,7 @@ let print_rules file =
21
25
pf " (action (run ocp-indent %%{dep:../%s} -o %%{target})))" file;
22
26
pf "";
23
27
pf "(rule";
24
- pf " (alias fmt)";
28
+ pf " (alias %s)" !alias;
29
pf " (action (diff ../%s %s.%s)))" file file formatted_ext;
30
pf ""
31
| _ -> ()
0 commit comments