From owner-freebsd-questions@FreeBSD.ORG Mon May 2 00:17:32 2011 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 536DF106564A for ; Mon, 2 May 2011 00:17:32 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mx01.qsc.de (mx01.qsc.de [213.148.129.14]) by mx1.freebsd.org (Postfix) with ESMTP id 151128FC0C for ; Mon, 2 May 2011 00:17:31 +0000 (UTC) Received: from r55.edvax.de (port-92-195-63-56.dynamic.qsc.de [92.195.63.56]) by mx01.qsc.de (Postfix) with ESMTP id 1959D3CA95; Mon, 2 May 2011 02:17:31 +0200 (CEST) Received: from r55.edvax.de (localhost [127.0.0.1]) by r55.edvax.de (8.14.2/8.14.2) with SMTP id p420HUna005065; Mon, 2 May 2011 02:17:30 +0200 (CEST) (envelope-from freebsd@edvax.de) Date: Mon, 2 May 2011 02:17:30 +0200 From: Polytropon To: freebsd-questions@freebsd.org Message-Id: <20110502021730.f87d654f.freebsd@edvax.de> In-Reply-To: <20110502021317.af30339c.freebsd@edvax.de> References: <761855.57021.qm@web120004.mail.ne1.yahoo.com> <20110502021317.af30339c.freebsd@edvax.de> Organization: EDVAX X-Mailer: Sylpheed 2.4.7 (GTK+ 2.12.1; i386-portbld-freebsd7.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: George Sanders Subject: Re: Any way to have login output AND use rsync/scp ? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Polytropon List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 May 2011 00:17:32 -0000 On Mon, 2 May 2011 02:13:17 +0200, Polytropon wrote: > On Sun, 1 May 2011 15:58:45 -0700 (PDT), George Sanders wrote: > > I have my .cshrc file run some basic netstat and 'w' commands so that when I log > > in, I can see at a glance what is going on on the system and notice any unusual > > login activity, etc. > > > > However this completely breaks both scp and rsync - they cannot function at all > > (apparently) with any kind of stdio output from the shell. > > > > Is there any way around this ? > > > Create a file ~/.login and put your commands (in sh syntax, > not csh) there. This file will only be executed at interactive > logins. See "man csh", section FILES for details. Sorry, wrote before thinking. :-) Of course ~/.login is csh syntax, as I would guess after (missed to) read the file's header which states: # .login - csh login script, read by login shell, after `.cshrc' at login. # see also csh(1), environ(7). So simply moving your commands from .cshrc to .login should be fully sufficient. -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ...