in reply to Re^8: Debugger actions: On which lines?
in thread Debugger actions: On which lines?

IMHO, none of the three reasons above really apply to Windows.

Show intent?

How does #!/usr/bin/perl say anything to a Windows user that has never used Unix or Linux? If you intend to inform the reader that this is a Perl program (hopefully the reader should know), you might as well add a comment:

# This is a Perl program that should be called as follows: # perl blahblah (args)
Probably clearer for a Win user..

help other scripts/utilities with file type/content discovery

Under Windows?

Portability?

Well, not under Windows... And, under Unix/Linux, I can think of at least half a dozen places where the Perl interpreter file might be located.

This is not to say that I don't get your points (I upvoted your post), I am just not fully convinced.

Replies are listed 'Best First'.
Re^10: Debugger actions: On which lines?
by Your Mother (Archbishop) on Aug 18, 2015 at 21:00 UTC

    Not too worried about "users," just power users and hackers who might see a .exe or something and want to peek. That style of comment is not best practice for Perl (use Pod) and useless for anyone who isn't a hacker or least knows how use the "cmd line." For portability I meant between platforms and the "proper" idiom for the script is #!/usr/bin/env perl so there are perhaps fewer places on *nix :P

    Anyone can of course do what she thinks best or easiest. It doesn't cost anything to have a shebang though and it could potentially save someone else some trouble. I am not pushing for the style but I would do it (if I were developing on Win these days but I haven't needed to for years).

      How interesting this has been.

      I do #!/usr/bin/perl -w by reflex. I have been criticised because it turns on warnings globally - but I could never see why I would not want that! This is a reason not to use "-w", but it is a bug not a feature.

      Thans every body, this has been fun!

      Arghhhh! I just spent 20 minutes of my life preparing a bug report using "perlbug". After crafting a splendid report (truly splendid) I was prompted to send it, I did and the stupid programme tried to send the report by port 25 which failed (I send mail in other ways) and after it failed as far as I can tell my bug report (did I say it was truly splendid?) has been lost for ever!!! Perhaps I should learn python\t\t\n\t!

      A very grumpy Worik

        My copy of perlbug contains:

        paraprint <<EOF; $0 has detected an error while trying to send your message: $error. Your message may not have been sent. You will now have a chance to sav +e a copy to disk. EOF SaveMessage();

        and

        sub SaveMessage { my $file_save = $outfile || "$progname.rep"; my $file = _prompt( '', "Name of file to save message in", $file_s +ave );

        So that is what is supposed to happen if there is a problem with sending the e-mail. I can certainly understand being very frustrated when that didn't happen.

        Note also that you can use "perlbug -F mybug.txt" if you want to use perlbug w/o it trying to send the e-mail for you.

        - tye