The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

Vulcan::File

SYNOPSIS

SYNOPSIS

my $file = Vulcan::File->new( '/etc/passwd' );

$file->munge( regex => qr/^foo\b/, length => 1, lazy => 1 )->commit();

METHODS

munge( %param )

seek: 'set' or 'end'
offset: number of lines from seek position
length: number of lines to remove
regex: a regular expression
lazy: default to end of file if regex match failed
line: a set of lines

commit( %param )

path: alternative path to commit
backup: back up original file