Keep the Rest¶
Aliases: repolish:keep-the-rest, repolish:keep-footer.
Everything from a marker line to the end of the file comes from your project file; the provider manages the head. This is the keep block with its end implied — and the direct descendant of the tail-capture regex that the multiregex workflow kept needing ("let me append my own tools after yours"). The marker line names the intention instead of hiding it in a pattern.
The classic case: .gitignore, where the provider ships canonical ignores and
the project's own entries accumulate at the bottom.
Worked example¶
Behavior¶
- If your file has no marker line, the template default tail ships — so fresh projects still get a sensible file.
- The marker line itself is preserved in the output; only the directive line is stripped.
- Supports the
|after-renderphase. - Compose it with multiregex to get "provider owns the values, developers own the tail" in one file — the exact lineage that led to keep blocks in the first place.