All of lore.kernel.org
 help / color / mirror / Atom feed
* Tcsh: Append output to a file
@ 2002-05-15  1:01 Axel H. Siebenwirth
  0 siblings, 0 replies; 5+ messages in thread
From: Axel H. Siebenwirth @ 2002-05-15  1:01 UTC (permalink / raw)
  To: linux-newbie

Hello!

For example I use "/usr/local/sbin/dsniff >& dsniff.log &" in a start-up
skript to log the output to a file. But everytime I start my computer a new
file "dsniff.log" is created.

My question is: How do I append to an existing file?


Thank you,
Axel Siebenwirth
-
To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.linux-learn.org/faqs

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Tcsh: Append output to a file
@ 2002-05-15  1:08 Ray Olszewski
  2002-05-15  1:17 ` Axel H. Siebenwirth
  0 siblings, 1 reply; 5+ messages in thread
From: Ray Olszewski @ 2002-05-15  1:08 UTC (permalink / raw)
  To: Axel H. Siebenwirth, linux-newbie

At 03:01 AM 5/15/02 +0200, Axel H. Siebenwirth wrote:
>Hello!
>
>For example I use "/usr/local/sbin/dsniff >& dsniff.log &" in a start-up
>skript to log the output to a file. But everytime I start my computer a new
>file "dsniff.log" is created.
>
>My question is: How do I append to an existing file?

/usr/local/sbin/dsniff >>& dsniff.log &

The double >> is the "append" instruction.


--
------------------------------------"Never tell me the odds!"---
Ray Olszewski                                        -- Han Solo
Palo Alto, CA           	 	         ray@comarre.com        
----------------------------------------------------------------

-
To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.linux-learn.org/faqs

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Tcsh: Append output to a file
  2002-05-15  1:08 Ray Olszewski
@ 2002-05-15  1:17 ` Axel H. Siebenwirth
  2002-05-15  2:44   ` lawson_whitney
  2002-05-15  6:52   ` Steven Smith
  0 siblings, 2 replies; 5+ messages in thread
From: Axel H. Siebenwirth @ 2002-05-15  1:17 UTC (permalink / raw)
  To: Ray Olszewski; +Cc: linux-newbie

Hi!

On Tue, 14 May 2002, Ray Olszewski wrote:

> At 03:01 AM 5/15/02 +0200, Axel H. Siebenwirth wrote:
> >Hello!
> >
> >For example I use "/usr/local/sbin/dsniff >& dsniff.log &" in a start-up
> >skript to log the output to a file. But everytime I start my computer a new
> >file "dsniff.log" is created.
> >
> >My question is: How do I append to an existing file?
> 
> /usr/local/sbin/dsniff >>& dsniff.log &
> 
> The double >> is the "append" instruction.

Okay. First off, thank you!
I confused myself. Shell chaos. I'm using tcsh as all my login shells. But
the startup scripts are all bash scripts. So I really asked my self why what
you told me works on command line but not from the script.

Can you please tell me how to the same thing for bash? :)

Thank you,
Axel Siebenwirth
-
To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.linux-learn.org/faqs

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Tcsh: Append output to a file
  2002-05-15  1:17 ` Axel H. Siebenwirth
@ 2002-05-15  2:44   ` lawson_whitney
  2002-05-15  6:52   ` Steven Smith
  1 sibling, 0 replies; 5+ messages in thread
From: lawson_whitney @ 2002-05-15  2:44 UTC (permalink / raw)
  To: axel; +Cc: linux-newbie

On Wed, 15 May 2002, Axel H. Siebenwirth wrote:

>
> Okay. First off, thank you!
> I confused myself. Shell chaos. I'm using tcsh as all my login shells. But
> the startup scripts are all bash scripts. So I really asked my self why what
> you told me works on command line but not from the script.
>
> Can you please tell me how to the same thing for bash? :)
>
> Thank you,
> Axel Siebenwirth
> -
First off, you don't _have_ to use bash for scripts.  Instead of
starting the script #!/bin/[ba]sh, it can start #!/bin/tcsh.

If you want to use bash, this should do it:

Script started on Tue May 14 22:38:27 2002
[whit@giftie whit]$ echo $SHELL >file 2>&1
[whit@giftie whit]$ echo $SHELL $SHELL >>file 2>&1
[whit@giftie whit]$ cat file
/bin/bash
/bin/bash /bin/bash
[whit@giftie whit]$ exit

Script done on Tue May 14 22:39:30 2002

Lawson
---oof---



________________________________________________________________
GET INTERNET ACCESS FROM JUNO!
Juno offers FREE or PREMIUM Internet access for less!
Join Juno today!  For your FREE software, visit:
http://dl.www.juno.com/get/web/.
-
To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.linux-learn.org/faqs

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Tcsh: Append output to a file
  2002-05-15  1:17 ` Axel H. Siebenwirth
  2002-05-15  2:44   ` lawson_whitney
@ 2002-05-15  6:52   ` Steven Smith
  1 sibling, 0 replies; 5+ messages in thread
From: Steven Smith @ 2002-05-15  6:52 UTC (permalink / raw)
  To: linux-newbie

[-- Attachment #1: Type: text/plain, Size: 348 bytes --]

> > >My question is: How do I append to an existing file?
> > /usr/local/sbin/dsniff >>& dsniff.log &
> Can you please tell me how to the same thing for bash? :)
/usr/local/sbin/dsniff >> dsniff.log &

if you just want output in the file,

/usr/local/sbin/dsniff >> dsniff.log 2>&1 &

if you want output and errors.

Steven Smith,
sos22@cam.ac.uk.

[-- Attachment #2: Type: application/pgp-signature, Size: 232 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2002-05-15  6:52 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-05-15  1:01 Tcsh: Append output to a file Axel H. Siebenwirth
  -- strict thread matches above, loose matches on Subject: below --
2002-05-15  1:08 Ray Olszewski
2002-05-15  1:17 ` Axel H. Siebenwirth
2002-05-15  2:44   ` lawson_whitney
2002-05-15  6:52   ` Steven Smith

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.