no_merge_conflict_markers
Flag <<<<<<< , =======, >>>>>>> , ||||||| markers at the start of a line — almost always left over from an unresolved merge. The anchor markers carry a trailing ref (<<<<<<< HEAD), so they never collide with prose; a bare ======= is reported only when the file also contains one of those anchors, because on its own a seven-character ======= is indistinguishable from a reST/Markdown setext heading underline (so docs trees no longer need to be excluded).
Options
Section titled “Options”This rule takes no kind-specific options.
Plus the common paths, level, id, and when fields. This table is generated from the JSON Schema; option types and defaults are authoritative.
Example
Section titled “Example”A source file with unresolved merge conflict markers
Section titled “A source file with unresolved merge conflict markers”The rule fires on this repository:
src/src/clean.rssrc/half_merged.rspub fn ok() {}<<<<<<< HEADours=======theirs>>>>>>> featureWith this .alint.yml:
version: 1rules: - id: no-conflict kind: no_merge_conflict_markers paths: "src/**/*" level: erroralint check reports:
--- src/half_merged.rs --------------------------------------------------------- x error no-conflict 1:1 unresolved merge conflict marker on line 1: "<<<<<<<"
Summary (1 violation): x 1 error 0 passing * 1 failingSource files with no leftover conflict markers
Section titled “Source files with no leftover conflict markers”This repository is compliant:
src/src/a.rssrc/docs.mdpub fn a() {}Conflict discussion: we use <<<<<< for ... (inline, no col-1 marker)With this .alint.yml:
version: 1rules: - id: no-conflict kind: no_merge_conflict_markers paths: "src/**/*" level: erroralint check reports:
v All 1 rule(s) passed.