App-CSVUtils
view release on metacpan or search on metacpan
script/csv-delete-fields view on Meta::CPAN
our $AUTHORITY = 'cpan:PERLANCAR'; # AUTHORITY
our $DATE = '2025-02-04'; # DATE
our $DIST = 'App-CSVUtils'; # DIST
our $VERSION = '1.036'; # VERSION
my $cmdline = Perinci::CmdLine::Any->new(
url => "/App/CSVUtils/csv_delete_fields/csv_delete_fields",
program_name => "csv-delete-fields",
log => 1,
read_config => 0,
read_env => 0,
use_utf8 => 1,
);
$cmdline->run;
# ABSTRACT: Delete one or more fields from CSV file
# PODNAME: csv-delete-fields
__END__
=pod
=encoding UTF-8
=head1 NAME
csv-delete-fields - Delete one or more fields from CSV file
=head1 VERSION
This document describes version 1.036 of csv-delete-fields (from Perl distribution App-CSVUtils), released on 2025-02-04.
=head1 SYNOPSIS
B<csv-delete-fields> B<L<--help|/"--help, -h, -?">> (or B<L<-h|/"--help, -h, -?">>, B<L<-?|/"--help, -h, -?">>)
B<csv-delete-fields> B<L<--version|/"--version, -v">> (or B<L<-v|/"--version, -v">>)
B<csv-delete-fields> [B<L<--debug|/"--debug">>|B<L<--log-level|/"--log-level=s">>=I<level>|B<L<--quiet|/"--quiet">>|B<L<--trace|/"--trace">>|B<L<--verbose|/"--verbose">>] [B<L<--exclude-field-pat|/"--exclude-field-pat=s">>=I<re>|B<L<-A|/"--exclude-fi...
See examples in the L</EXAMPLES> section.
=head1 DESCRIPTION
(No description)
=head1 OPTIONS
C<*> marks required options.
=head2 Main options
=over
=item B<--ignore-unknown-fields>
When unknown fields are specified in --include-field (--field) or --exclude-field options, ignore them instead of throwing an error.
=item B<--input-skip-num-lines>=I<s>
Number of lines to skip before header row.
This can be useful if you have a CSV files (usually some generated reports,
sometimes converted from spreadsheet) that have additional header lines or info
before the CSV header row.
See also the alternative option: C<--input-skip-until-pattern>.
=item B<--input-skip-until-pattern>=I<s>
Skip rows until the first header row matches a regex pattern.
This is an alternative to the C<--input-skip-num-lines> and can be useful if you
have a CSV files (usually some generated reports, sometimes converted from
spreadsheet) that have additional header lines or info before the CSV header
row.
With C<--input-skip-num-lines>, you skip a fixed number of lines. With this
option, rows will be skipped until the first field matches the specified regex
pattern.
=item B<--show-selected-fields>
Show selected fields and then immediately exit.
=back
=head2 Field selection options
=over
=item B<--exclude-all-fields>
Shortcut for --exclude-field-pat=.*, effectively excluding all fields.
See C<--exclude-field-pat>.
=item B<--exclude-field-pat>=I<s>
Field regex pattern to exclude, takes precedence over --field-pat.
=item B<--exclude-field>=I<s@>, B<-F>
Field names to exclude, takes precedence over --fields.
Can be specified multiple times.
=item B<--exclude-fields-json>=I<s>
Field names to exclude, takes precedence over --fields (JSON-encoded).
See C<--exclude-field>.
=item B<--include-all-fields>
( run in 0.561 second using v1.01-cache-2.11-cpan-39bf76dae61 )