The literal translation of that would be do.
do 'filefoo';
Having said that, I'm not sure a literal translation from bash to Perl
would make a good program. Is there any reason you need to translate it?
Well, yes. It doesn't work.
I want Nanoblogger to work for me on a FreeBSD system. I have overcome many
obstacles so far, but Nanoblogger occasionally emits empty documents,
apparently at random, and this is a silent gotcha. Clearing cache,
previously generated documents, and so forth, on each attempt results in
different pages that coming out empty. On various runs I get every document
out right sometimes, but rarely get them all out. I suspect BASH limits
might be the culprit, but they are all maxed out.
I suspect the author's point in Nanoblogger is all the wonderful things you
can do with Bash and stream tools (I've learned more sed in this process than
I ever wanted to know). And when it works, it works great.
I, however, am not interested in a Bash demo, but in a working blog. The
main features I like about Nanoblogger are:
*flat file database
*only requires a command line editor
*does not require a javascript-enabled browser
I want to use it to generate static pages. I won't have direct entry of
user comments with forms, etc. Security, in short, is no issue. But
avoiding OO perl modules is. I'm not interested in a bunch of scoping crap
and inscrutable notation. And the reason this particular question is here
is because when I consult the perl docs with simple issue like this,
I get a bunch of Module::OO::Crap instead of a simple explanation of how to
include some code from another file.
This is why I fear Perl 6: because so far as I can tell, it only promises
more of the same.