-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathlangcop_all.nim
37 lines (35 loc) · 1.15 KB
/
langcop_all.nim
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
31
32
33
34
35
36
37
import os, strformat, osproc
let list = @[
# ("case_equality", "style"),
# ("circular_argument_reference", "lint"),
# ("disjunctive_assignment_in_constructor", "lint"),
# ("boolean_symbol", "lint"),
# ("variable_name", "naming"),
# ("method_length", "metrics"),
# ("begin_block", "style"),
# ("single_line_methods", "style"),
# ("send", "style"),
# ("end_block", "style"),#
("symbol_literal", "style"),
("if_with_semicolon", "style"),
("nested_ternary_operator", "style"),
("method_missing_super", "style"),
("multiline_ternary_operator", "style"),
("proc", "style"),
("when_then", "style"),
("inline_comment", "style"),
("colon_method_definition", "style"),
("struct_inheritance", "style"),
("class_and_module_camel_case", "naming"),
("method_name", "naming")
# we choose ~20 of the simplest and shortest cops for beginning
# we choose several different and maybe several big!
# and maybe if batsov wants some for example
]
# ("symbol_literal", "style"),
# ("send", "symbol")
for (label, directory) in list:
echo &"{label} {directory}"
let status = execCmd(&"./langcop {label} {directory}")
if status == 130:
quit(1)