DOKK / manpages / debian 12 / opalmod / OpaL::read.3pm.en
read(3pm) User Contributed Perl Documentation read(3pm)

OpaL::read - Perl extension for reading files and commands.

  use OpaL::read qw(functions);

No functions or variables are exported automaticly so you have to specify them here.

OpaL::read is used for reading files and commands.

All functions are autoloaded so they will not be loaded into memory if you have not used them before.

Reads the content of the specified file and returns a list with the all lines.

USAGE:
@foo = "readfile"($filename);

Reads the first line of the specified file and returns a scalar with that line.

USAGE:
$foo = "readfileline"($filename);

Reads the content of the specified file and returns a scalar with the entire content.

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

Reads the content from the output of the specified command and returns a list with the all lines.

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

Reads the first line from output of the specified command and returns a scalar with that line.

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

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

USAGE:
$foo = "readscalarcommand"($command);

Ola Lundqvist <ola@inguza.com>

perl(1).

2022-03-24 perl v5.34.0