bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Should this be this way?


From: Chet Ramey
Subject: Re: Should this be this way?
Date: Thu, 28 Feb 2013 10:22:08 -0500
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:17.0) Gecko/20130216 Thunderbird/17.0.3

On 2/27/13 11:05 PM, Linda Walsh wrote:
> 
> 
> Greg Wooledge wrote:
>>> How often, when at a terminal, do you type #!/bin/bash before every line?
>>
>> When I've put the contents into a file?  Every. single. time.
> ---
> Then when I press 'v' to edit the command line in a text editor --
> maybe 'bash' should insert such a line?  It's converted your command line
> into an editable file.  But it hasn't put the #!/bin/bash at the front.

This is a bad example.  The file that is the result of the vi-mode `v'
command is run as if it were sourced with `.'.  It's not run as if it
were a shell script.



-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU    address@hidden    http://cnswww.cns.cwru.edu/~chet/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]