Unix and Linux Discussions Tagged with pattern matching |
|
Thread / Thread Starter |
Last Post |
Replies |
Views |
Forum |
|
|
|
3 |
7,009 |
UNIX for Beginners Questions & Answers |
|
|
|
3 |
2,408 |
UNIX for Beginners Questions & Answers |
|
|
|
5 |
7,930 |
UNIX for Beginners Questions & Answers |
|
|
|
2 |
5,633 |
UNIX for Beginners Questions & Answers |
|
|
|
4 |
4,922 |
UNIX for Beginners Questions & Answers |
|
|
|
3 |
1,580 |
Shell Programming and Scripting |
|
|
|
6 |
1,318 |
Shell Programming and Scripting |
|
|
|
9 |
2,913 |
Shell Programming and Scripting |
|
|
|
5 |
13,603 |
UNIX for Beginners Questions & Answers |
|
|
|
3 |
1,593 |
Shell Programming and Scripting |
|
|
|
3 |
2,430 |
Shell Programming and Scripting |
|
|
|
5 |
14,285 |
UNIX for Dummies Questions & Answers |
|
|
|
6 |
7,000 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
3,215 |
Shell Programming and Scripting |
|
|
|
4 |
2,998 |
Shell Programming and Scripting |
|
|
|
8 |
8,208 |
Shell Programming and Scripting |
|
|
|
2 |
1,868 |
Shell Programming and Scripting |
|
|
|
3 |
7,273 |
Shell Programming and Scripting |
|
|
|
1 |
5,099 |
UNIX for Dummies Questions & Answers |
|
|
|
7 |
3,300 |
Shell Programming and Scripting |
|
|
|
3 |
7,079 |
Shell Programming and Scripting |
|
|
|
5 |
6,940 |
Shell Programming and Scripting |
|
|
|
2 |
8,908 |
Shell Programming and Scripting |
|
|
|
2 |
8,492 |
UNIX for Dummies Questions & Answers |
|
|
|
3 |
4,902 |
UNIX for Advanced & Expert Users |
|
|
|
9 |
10,981 |
Shell Programming and Scripting |
|
|
|
7 |
21,108 |
Shell Programming and Scripting |
|
|
|
3 |
2,896 |
Shell Programming and Scripting |
|
|
|
0 |
6,285 |
UNIX for Advanced & Expert Users |
|
|
|
9 |
74,267 |
Shell Programming and Scripting |
|
|
|
2 |
3,942 |
Shell Programming and Scripting |
|
|
|
1 |
6,234 |
Shell Programming and Scripting |
|
|
|
6 |
2,680 |
Shell Programming and Scripting |
|
|
|
0 |
2,285 |
Programming |
|
|
|
0 |
3,208 |
UNIX for Advanced & Expert Users |
|
|
|
0 |
2,300 |
UNIX for Dummies Questions & Answers |
|
|
|
7 |
3,427 |
Shell Programming and Scripting |
|
|
|
1 |
1,853 |
Shell Programming and Scripting |
|
|
|
3 |
3,436 |
UNIX and Linux Applications |
|
|
|
2 |
2,221 |
Shell Programming and Scripting |
PTARGREP(1) Perl Programmers Reference Guide PTARGREP(1)
NAME
ptargrep - Apply pattern matching to the contents of files in a tar archive
SYNOPSIS
ptargrep [options] <pattern> <tar file> ...
Options:
--basename|-b ignore directory paths from archive
--ignore-case|-i do case-insensitive pattern matching
--list-only|-l list matching filenames rather than extracting matches
--verbose|-v write debugging message to STDERR
--help|-? detailed help message
DESCRIPTION
This utility allows you to apply pattern matching to the contents of files contained in a tar archive. You might use this to identify all
files in an archive which contain lines matching the specified pattern and either print out the pathnames or extract the files.
The pattern will be used as a Perl regular expression (as opposed to a simple grep regex).
Multiple tar archive filenames can be specified - they will each be processed in turn.
OPTIONS
--basename (alias -b)
When matching files are extracted, ignore the directory path from the archive and write to the current directory using the basename of
the file from the archive. Beware: if two matching files in the archive have the same basename, the second file extracted will
overwrite the first.
--ignore-case (alias -i)
Make pattern matching case-insensitive.
--list-only (alias -l)
Print the pathname of each matching file from the archive to STDOUT. Without this option, the default behaviour is to extract each
matching file.
--verbose (alias -v)
Log debugging info to STDERR.
--help (alias -?)
Display this documentation.
COPYRIGHT
Copyright 2010 Grant McLean <grantm@cpan.org>
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
perl v5.18.2 2018-08-17 PTARGREP(1)