Options
--mode, --min-tokens, --min-lines, and --min-occurrences fall back to
the dupes block of a config file before their built-in
defaults, so a calibration is committed once instead of repeated on every
invocation. That block is also how a combined roe check
run, which takes no dupes flags, picks the calibration up.
Exact vs. semantic mode
By default,roe dupes only matches code that’s identical token-for-token.
Pass --mode semantic to also catch blocks that were copied and then had
their variable names or numeric literals changed, but are otherwise
structurally the same: identifiers and numeric literals are normalized to a
shared placeholder before matching, while string literals, keywords, and
punctuation always keep their exact text.
Ignoring files
Duplicates span multiple files, so there’s no inline suppression comment for them. Instead, use ignore globs in a config file: the top-levelignore list applies to every command, and the dupes.ignore
list adds patterns only the duplicate analysis honours — so accepting an
intentional duplicate doesn’t cost the file its dead-code and health
coverage.
roe.json