Lint subcommand detects problems in Satyristes, OPAM files, and SATySFi files.
satyrographos [--verbose] [--script <satyristes-path>] [-W <warning-expr>]
--verbose
makes the output verbose--script
points toSatyristes
file. Its default value is./Satyristes
.-W
can enable/disable warnigs.
Each problem is classified one problem class. For example, the following problems belong to lib/version
problem class.
- A Satyrographos library has an empty version id.
- A Satyrographos library has an invalid version id.
Each OPAM Lint error/warning is considered as problem class opam-file/lint/<opam-warning-no>
. For example, an empty synopsis
field causes opam-file/lint/47
.
-W
option is added to disable warnings/errors being reported by lint
subcommand.
For now, -W
option can disable not only warning but also errors. This behavior should be revised when lint subcommand is stable enough since errors should not be turned off.
-W
option takes a warning expression. The grammar is following.
main ::=
| exprs
exprs ::=
| expr ( "," expr )*
-- List of exprs
| ( atom "/" )* "{" exprs "}"
-- Common prefix for the exprs
expr ::=
| ( "+" | "-" ) glob
-- Enable or disable warnings matching the glob
glob ::=
| "*"
| atom
| atom "/" glob
| "{" globList "}"
-- Alternative choose
globList ::=
| glob
| glob "," globList
atom ::=
| id
| range
id ::=
| idCharFirst idChar
idCharFirst ::=
| alphaNum
idChar ::=
| idCharFirst
| "_" | "-" | "."
range ::=
| digit ".." digit
Examples:
+a/b
enables warnings prefixed witha/b
, e.g.,a/b
,a/b/c
, but nota/bc
ora
.+a/*
enables warnings prefixed witha/
, e.g.,a/b
,a/b/c
, but nota/bc
ora
.-*,+a
disables all the warnings but ones prefixed witha
.a/{+b,-c}
is equivalent to+a/b,-a/c
+a/{b,c}
is equivalent toa/{+b,+c}
so as to+a/b,+a/c
.+{1..3,a}
is equivalent to+1,+2,+3,+a
0
if no errors are detected.1
if errors are detected.