Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re^2: Top 10 reasons to start using ack

by petdance (Parson)
on Nov 30, 2006 at 05:28 UTC ( [id://586865]=note: print w/replies, xml ) Need Help??


in reply to Re: Top 10 reasons to start using ack
in thread Top 10 reasons to start using ack

A couple of thoughts:

* I wouldn't have it on by default. It would only be via the -A,--archive switch, for example.

* How would I show the resultant filename? If the file is in a tarball, what do I show for the filename?

xoxo,
Andy

  • Comment on Re^2: Top 10 reasons to start using ack

Replies are listed 'Best First'.
Re^3: Top 10 reasons to start using ack
by diotalevi (Canon) on Nov 30, 2006 at 05:35 UTC

    I'd be sane to treat these containers like directories. Directories are just another kind of container. Given a tarball baz.tgz in /foo/bar containing the files a and b/c you'd tell the user about matches in the paths /foo/bar/baz.tgz/a and /foo/bar/baz.tgz/b/c. I think Windows "Compressed Folders" work like this.

    ⠤⠤ ⠙⠊⠕⠞⠁⠇⠑⠧⠊

      I could see using "foo.gz" as the filename for a standalone file, using your streaming method.

      For tarballs, though, I would have to extract to a temporary directory and delve through that, and that means write privileges that I don't want to assume.

      xoxo,
      Andy

        You can't extract a file at a time out to a temporary directory using File::Temp? Or even better - don't even write it back to disk.

        ⠤⠤ ⠙⠊⠕⠞⠁⠇⠑⠧⠊

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://586865]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (4)
As of 2024-04-25 07:54 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found