From owner-freebsd-questions Sun Jul 28 8:16:42 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 022B437B401 for ; Sun, 28 Jul 2002 08:16:33 -0700 (PDT) Received: from smtp.infracaninophile.co.uk (happy-idiot-talk.infracaninophile.co.uk [81.2.69.218]) by mx1.FreeBSD.org (Postfix) with ESMTP id A078243E42 for ; Sun, 28 Jul 2002 08:16:30 -0700 (PDT) (envelope-from m.seaman@infracaninophile.co.uk) Received: from happy-idiot-talk.infracaninophile.co.uk (localhost [IPv6:::1]) by smtp.infracaninophile.co.uk (8.12.5/8.12.5) with ESMTP id g6SFGTdG001861; Sun, 28 Jul 2002 16:16:29 +0100 (BST) (envelope-from matthew@happy-idiot-talk.infracaninophile.co.uk) Received: (from matthew@localhost) by happy-idiot-talk.infracaninophile.co.uk (8.12.5/8.12.5/Submit) id g6SFGOR3001860; Sun, 28 Jul 2002 16:16:24 +0100 (BST) Date: Sun, 28 Jul 2002 16:16:24 +0100 From: Matthew Seaman To: Paulo Roberto Cc: "D. Penev" , freebsd-questions@FreeBSD.ORG Subject: Re: starting fetchmail from ppp.linkup on FreeBSD 4.6 Message-ID: <20020728151624.GB94488@happy-idiot-talk.infracaninophi> References: <20020728100127.GA371@earth.dpsca.bg> <20020728134345.52515.qmail@web14910.mail.yahoo.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20020728134345.52515.qmail@web14910.mail.yahoo.com> User-Agent: Mutt/1.5.1i Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sun, Jul 28, 2002 at 06:43:45AM -0700, Paulo Roberto wrote: > --- "D. Penev" wrote: > > and try > > this in ppp.linkup: > > > > ! /usr/local/bin/fetchmail -d > > Should I drop the 'sh' after the '!'?? > BTW what is this '!' for? From my understanding I am not denying any > argument... (I didn't find it on the manual...) It's '!' with the meaning of "shell escape", as you get in eg. the ftp program, not '!' meaning 'not' as you get in most programming languages. If you think it's too confusing use the ppp 'shell' command instead: shell /usr/local/bin/fetchmail ... Similarly, to have commands executed in the background, you can use either of: bg command !bg command The meaning is exactly the same. Saying '! sh foo' means that you want ppp to invoke a shell to run the 'sh' program, and have 'sh' run 'foo' for you. If that all seems needlessly complicated, that's because it is --- using sh like that is pretty redundant. The great exception to that is to use 'sh -c' to run compound commands interpreting shell meta-characters: shell sh -c "[ -d dir ] || mkdir dir ; cat > dir/foo" Cheers, Matthew -- Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks Savill Way Tel: +44 1628 476614 Marlow Fax: +44 0870 0522645 Bucks., SL7 1TH UK To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message