read(3pm)

πŸ“¦
version 0.2.2.1build1 Β· 3 versions
, in ubuntu resolute, ubuntu stonking

πŸ’– read(3pm) πŸ’–

okay bestie, welcome to OpaL::read β€” a Perl extension for reading files and commands, straight out of the User Contributed Perl Documentation collection. it's giving "tiny module, big helper energy" ✨


🌸 NAME 🌸

OpaL::read β€” Perl extension for reading files and commands. that's it, that's the whole vibe 🫢


πŸŽ€ SYNOPSIS πŸŽ€

use OpaL::read qw(functions);

no functions or variables are exported automatically, so you have to specify them here yourself. the module is not gonna read your mind, bestie, you gotta ask πŸ’…


πŸ¦‹ DESCRIPTION πŸ¦‹

OpaL::read is used for reading files and commands. that's the whole job description and honestly? iconic ✨

all functions are autoloaded, so they will not be loaded into memory if you have not used them before. it's the "show up only when summoned" lifestyle and we respect it πŸ’…


πŸ‘‘ FUNCTIONS πŸ‘‘

πŸ’œ readfile

reads the content of the specified file and returns a list with all the lines. every single line, no skimping πŸ“

USAGE:

@foo = "readfile"($filename);

🌸 readfileline

reads the first line of the specified file and returns a scalar with that line. just the one. the opening line, the main character πŸŽ€

USAGE:

$foo = "readfileline"($filename);

⭐ readscalarfile

reads the content of the specified file and returns a scalar with the entire content. the whole thing, in one variable, no cap πŸ’–

USAGE:

$foo = "readscalarfile"("filename");

πŸ”₯ readcommand

reads the content from the output of the specified command and returns a list with all the lines. yes bestie, we're running commands and reading what they say back 🌈

USAGE:

@foo = "readcommand"("command");

🧚 readcommandline

reads the first line from the output of the specified command and returns a scalar with that line. one line only, blink and it's over 😭

USAGE:

$foo = "readcommandline"("command)";

πŸ’€ readscalarfile

reads the content for the output of the specified file and returns a scalar with the entire content.

not me pointing out that this heading says readscalarfile but the usage line calls readscalarcommand 🫠 the manpage said what it said, and we are keeping it exactly as written. no editing the sacred text, periodt.

USAGE:

$foo = "readscalarcommand"($command);

🫢 AUTHOR 🫢

Ola Lundqvist <ola@inguza.com> β€” the icon who wrote all this πŸ’œ


🌈 SEE ALSO 🌈


that's the whole page, bestie πŸ’– this was read(3pm), perl v5.40.1, dated 2025-12-17 β€” mwah, slay, go read some files πŸ“βœ¨

πŸ“¦ where this page comes from