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: Greg Wooledge
Subject: Re: Should this be this way?
Date: Tue, 26 Feb 2013 16:45:23 -0500
User-agent: Mutt/1.4.2.3i

On Tue, Feb 26, 2013 at 01:27:35PM -0800, Linda Walsh wrote:
>       Except it isn't a script -- it's input that came from
> the terminal, that got repetitively edited using vi mode, until it got
> saved in a file so it could continue to be edited, and stay on the screen
> while executing it in the original window.

If it's in a file, it is a script.

Do note that commands in a file are not equivalent to commands typed into
an interactive shell.  If the commands set variables or change directory
or toggle shell options, those changes won't persist because you're running
a script, and they go away when the script terminates.  Maybe you want a
shell function instead.

> 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.



reply via email to

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