in reply to Re: Looking for suggestions for accessing/running scripts needed by a local Perl library
in thread Looking for suggestions for accessing/running scripts needed by a local Perl library

WRT #1, my modules sometimes need to execute scripts like the export functionality I mentioned. There is no way I could find to dump out Contacts without a GUI other than using an applescript.

WRT #2, I think it's mostly a security issue and it's easy to inject bad stuff into poor written command run by system. But since my modules are just for my own use on my own, local machine, I'm not sweating any security issues. I've got bigger problem if someone has hacked my machine and can pass nasty things to my perl scripts.

$PM = "Perl Monk's";
$MC = "Most Clueless Friar Abbot Bishop Pontiff Deacon Curate Priest Vicar Parson";
$nysus = $PM . ' ' . $MC;
Click here if you love Perl Monks

  • Comment on Re^2: Looking for suggestions for accessing/running scripts needed by a local Perl library

Replies are listed 'Best First'.
Re^3: Looking for suggestions for accessing/running scripts needed by a local Perl library
by NERDVANA (Priest) on Jan 24, 2024 at 18:07 UTC
    If I wanted to do it quickly because the details didn't matter much, I would just take the non-perl scripts and give them a distinctive name (unlikely to interfere with regular commandline use) and put them in ~/bin

    If I wanted a clean solution that was CPAN-looking (even if not going there yet) I would build a module with Dist::Zilla and put the non-perl scripts in ./share and then access them with File::ShareDir.

    Any external script that *was* perl, I would refactor into a module and put it in my module path. Well.. unless it was massive and complex and written by someone else, then maybe I would just shell out to it. But I would at least *intend* to refactor it into a module some day.