fastmod
fastmod copied to clipboard
Allow deletion
when I was trying to remove a matched set of configurations, I realized that fastmod default replacing the config with an empty line instead:
fastmod 'some-matching-config.*\n.*\n.*\n' ''
It would be nice to have a --delete flag that, instead of replacing existing matches with an empty line, it would just delete the matching lines.
Fastmod doesn't try to insert extra lines, it just does the replacement you specify. Couple potential fixes:
- Did you try the
-moption? - Perhaps you needed to match and remove one extra newline character?
closing because there has been no reply for almost 1 year; feel free to reply and reopen if my suggestions did not help