"be consistent" | |
PerlMonks |
Re^2: threads, forks and SSHby serf (Chaplain) |
on Dec 15, 2015 at 13:31 UTC ( [id://1150374]=note: print w/replies, xml ) | Need Help?? |
Meh about:
You have open and print, you have unlink, and you have ways of checking that what you wanted to do worked correctly. Perl isn't a shell script. I would suggest that it's more reliable, more efficient, more cross-OS portable, and generally better practice to do these things natively in Perl than shelling out via system. I get given grief at my $JOB by "scripts" that people who don't know Perl have written in Perl which should be in Perl but are full of awk and sed and grep and wc pipes and other badness. These scripts spawn many more processes than they need to, use more memory, and end up doing knarly things like jamming up, failing silently or causing excessive IO over NFS etc, bringing down our systems. When we post code on perlmonks, people who don't know as much as we do will take what we've written without understanding it and use it thinking it's the *right* way to do it. I think we should try and be responsible and steer them in the right direction. /me dismounts soapbox
In Section
Seekers of Perl Wisdom
|
|