Mailing List Archive
tlug.jp Mailing List tlug archive tlug Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]Re: [tlug] displaying executed commands in shell scripts
- Date: Fri, 8 Jun 2007 16:10:27 +0900
- From: Mattia Dongili <malattia@example.com>
- Subject: Re: [tlug] displaying executed commands in shell scripts
- References: <a96ae3bb0706072143x7a10cd22kf1d86aca73b97cbf@mail.gmail.com> <4668E55B.3020505@gmo.jp> <a96ae3bb0706072309g25478fe5qcb237d2fd1e23f9@mail.gmail.com>
- User-agent: Mutt/1.5.13 (2006-08-11)
On Fri, Jun 08, 2007 at 03:09:16PM +0900, Hector Akamine wrote: > Dave, Chris, Erin, > Thanks for your help > > On 6/8/07, Erin D. Hughes <erin-hughes@example.com> wrote: > > > >Maybe try this. > > > ><poor attempt at code> > >#!/bin/bash > >echo ls > >ls > >exit > ></poor attempt at code> > > I was doing something like this, but got tired after doing the same > thing for a script with more than 3 lines (I'm lazy :-)) do it fancy: -- 8< -- #!/bin/sh magenta='\e[0;35m' clear='\e[0m' ecmd() { echo -e "# ${magenta}$@example.com" $@ } ecmd ls ecmd ps ax -T ecmd echo "I'm the script $0" -- 8< -- > Dave's tip (adding set -x and set +x in the part of the script I want > the commands to be shown) did the trick. arigato! sorry for the useless comment :) -- mattia :wq!
- References:
- [tlug] displaying executed commands in shell scripts
- From: Hector Akamine
- Re: [tlug] displaying executed commands in shell scripts
- From: Erin D. Hughes
- Re: [tlug] displaying executed commands in shell scripts
- From: Hector Akamine
Home | Main Index | Thread Index
- Prev by Date: Re: [tlug] displaying executed commands in shell scripts
- Next by Date: Re: [tlug] displaying executed commands in shell scripts
- Previous by thread: Re: [tlug] displaying executed commands in shell scripts
- Next by thread: Re: [tlug] displaying executed commands in shell scripts
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links