Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re^3: How to read contents of a file without opening it and print the contents

by zek152 (Pilgrim)
on Jun 10, 2011 at 13:50 UTC ( [id://909122]=note: print w/replies, xml ) Need Help??


in reply to Re^2: How to read contents of a file without opening it and print the contents
in thread How to read contents of a file without opening it and print the contents

That's why I put the word open in quotes.

In your example I would say that "opening" /dev/hda1 means that you are "opening" a set of which the file is a subset. "Opening" a set implies that you have "opened" all subsets. (note the continued use of quotation marks)

Because I know that someone will point out that opening a set does not imply opening all subsets (example: a box filled with other boxes) I will clarify that in this case I am refering to sets that contain only singletons (in this case bytes or blocks) as elements.

Update: fixed moderate typo.

  • Comment on Re^3: How to read contents of a file without opening it and print the contents

Replies are listed 'Best First'.
Re^4: How to read contents of a file without opening it and print the contents
by Anonymous Monk on Jun 10, 2011 at 14:05 UTC
    I'm going to have settle for merely hiding the open in a system call:
    `cat filename > /dev/lp0`

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others about the Monastery: (3)
As of 2026-01-21 16:58 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What's your view on AI coding assistants?





    Results (125 votes). Check out past polls.

    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.