I wrote this module to scratch an itch but it wasn't mine. I kept seeing queries on usenet for how to read a file backwards, line by line. The Perl Cookbook has a recipe for this but it does a foward scan of the file and stores the offsets of each line and then opens the file again and seeks to those offsets to read the lines. I was not happy with this solution and paled to think about it when it processed some very large log files. So hunkered down and designed this module to be efficient and simple to use. It has become the standard answer to the aforementioned query. And the most amusing thing of all is that I have yet to use it.
I had long used my own little slurp functions as many times I have needed to process whole files rather than loop over their lines. In the fall of 2003, I got the idea to write an article about slurping for perl.com but I was told that creating a module along with the article was a better thing. So researched CPAN and found some slurping modules but nothing that was up to my flexibility and efficiency standards. So I wrote this module and took over the File::Slurp CPAN namespace from its previous owner (he graciously turned it over to me). The article was published and I have receieved many positive responses to it. File::Slurp is being used more and more and several modules now list it as a dependency.
This module was written as a project for pobox.com which is using postfix for its mail server. It supports communications with postfix's services in any of its standard formats.
This was my first attempt at serious Perl 5 coding. I am embarrassed to look at it now but I still like its concepts and features. And it is good for me (and you! :) to look at to see my growth in Perl coding style. Even though CPAN doesn't need another @ARGV parser I think this is different than all the others out there. It desperately needs a full rewrite. Any volunteers? :-)
See this page for a description of Stem.