help-bash
[Top][All Lists]
Advanced

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

Re: [Help-bash] Adding prefix to commands automatically printed when `se


From: Greg Wooledge
Subject: Re: [Help-bash] Adding prefix to commands automatically printed when `set -v` is enabled
Date: Mon, 30 Mar 2015 07:58:31 -0400
User-agent: Mutt/1.4.2.3i

On Sun, Mar 29, 2015 at 09:23:18AM -0500, Peng Yu wrote:
> In some other languages, for example, in R, not only the command
> running can be printed but also a prompt string is prepended to the
> command so that it is easy to see which line is the command and which
> line is the output. I don't think this feature is available when set
> -v is enabled (If it is available, please let me know). If not, is it
> a useful feature to be added to bash in the future?

Why not use set -x instead?  Not only does it print a "prompt" at the
start of each command, but you can configure its content (by setting PS4).
I've never found a use for set -v.



reply via email to

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