On Mar 4, 2005, at 3:39 PM, der.hans wrote:
> Am 04. Mar, 2005 schwätzte Lynn David Newton so:
>>> #!/bin/sh
>>>
>>
>> der.hans> Good, always leave the second line blank.
>>
>> Whereas I have included a blank line *always* in any
>> script that uses a shebang, I've done so mainly because
>> it looks good. I'm sure I've seen scripts that don't
>> have one. Therefore, my question is whether there is a
>> technical reason why a blank line should be there? I
>> tend to doubt it, and have never read anything about
>> this that I can recall. (I probably would have
>> remembered it.)
>
> There used to be. I think it was specifically for Perl scripts. Don't
> know
> if it really matters anymore.
>
> I figure the extra character doesn't take much space, it makes the file
> much more readable and it keeps me from running into whatever obscure
> bug
> there was that required a blank line :).
If you can find a reference to why this was the case, I'd really love
to see it. I spent about 15 minutes searching for this and while I
found a few fleeting references to perl scripts having to have a blank
second line (invariably followed by somebody saying "Why? I've never
had to do that") I couldn't find anything that even attempted to
explain why and when.
Personally, I haven't written enough perl scripts to say one way or
another. I have written more than my share of sh shell scripts and
while I usually leave the second line blank or start it with a comment,
I've never insisted on it and have never had a problem.
Kurt
---------------------------------------------------
PLUG-discuss mailing list -
PLUG-discuss@lists.plug.phoenix.az.us
To subscribe, unsubscribe, or to change you mail settings:
http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss