File::ReadSimple - Perl extension for making filehandling very easy for not-so good Perl Programmers.
use File::ReadSimple; file_read ("1.txt" or "ls -la |"); file_read_line("1.txt or "ls -la |","2"); file_bulk_read_line("1.txt" or "ls -la |","2","5"); file_read_last_lines("1.txt" or "ls -la |","2"); file_read_first_lines("1.txt" or "ls -la |","2"); file_read_odd_lines("1.txt" or "ls -la |"); file_read_even_lines("1.txt" or "ls -la |"); file_grep_word ("1.txt" or "ls -la |"); file_word_replace("1.txt" or "ls -la","abc","xyz"); file_grep_word_line_no("1.txt" or "ls -la"); file_tail("1.txt");
This module wraps many of the routine Filehandling/Command output handling tasks performed by Perl users/programmers. The reason for the development of the module is to help people use filehandling more efficiently and easily. Following is the way these functions can be used.
Function Name:file_read Description: To read a file or command output
Function:file_read_line Description: To read a specific line from the a file or command ouput
Function:file_bulk_read_line Description: To read range of lines from a file or command output
Function:file_read_last_lines Description:to read range of lines from the end of the file or command output
Function:file_read_first_lines Description:To read range of lines from the start of the file or command output
Function:file_read_odd_lines Description:To read odd lines from file or command output
Function:file_read_even_lines Description:To read even no lined from a file or command output
Function:file_grep_word Description:To find a lines containing the word from a file or command output
Function:file_word_replace Description:To find a word and replace with another word in a file or command output
Function:file_grep_word_line_no Description:To display the lines with nos where the word given if found from the file or command output
Function:file_tail Description:To continuously follow file output or command output i.e tail -f in UNIX.
None by default.
Nitin Harale, <nitin.harale@yahoo.com>
Copyright (C) 2006 by Super-User
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.
To install File::ReadSimple, copy and paste the appropriate command in to your terminal.
cpanm
cpanm File::ReadSimple
CPAN shell
perl -MCPAN -e shell install File::ReadSimple
For more information on module installation, please visit the detailed CPAN module installation guide.