From owner-freebsd-questions Tue Aug 6 6:42:56 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 10E0C37B400 for ; Tue, 6 Aug 2002 06:42:53 -0700 (PDT) Received: from janeway.vonbek.dhs.org (bgm-24-24-79-198.stny.rr.com [24.24.79.198]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8B12B43E3B for ; Tue, 6 Aug 2002 06:42:52 -0700 (PDT) (envelope-from syborg@stny.rr.com) Received: by janeway.vonbek.dhs.org (Postfix, from userid 507) id 028E64FC8A; Tue, 6 Aug 2002 09:42:58 -0400 (EDT) Received: from localhost (localhost [127.0.0.1]) by janeway.vonbek.dhs.org (Postfix) with ESMTP id F13364A0D; Tue, 6 Aug 2002 09:42:58 -0400 (EDT) Date: Tue, 6 Aug 2002 09:42:58 -0400 (EDT) From: John Bleichert X-X-Sender: syborg@janeway.vonbek.dhs.org Reply-To: John Bleichert To: Roman Neuhauser Cc: Grant Cooper , Subject: Re: executing a file in general In-Reply-To: <20020806133059.GX1066@freepuppy.bellavista.cz> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII 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 > > From: "Grant Cooper" > > To: > > Subject: executing a file in general > > Date: Tue, 6 Aug 2002 07:04:57 -0600 > > > > I normally use sh to execute a shell file even though some examples > > don't do it. I figure it has to do something with my shell. And than > > there are other times its not a script, but an executable file. Some > > files I can't run. Is there a command to man for this op? Or something > > to get me started? > > > > For example: > > # var/qmail/bin/qmail-popup blah /bin/checkpassword pwd > > invalid command or file name - couldn't do a sh either. And I am > > running from route. > If you start a command string with a directory without a leading '/' your shell will look in your current working directory for that directory, and if it doesn't find it, the command won't work. This is a relative path. If you start a command string with a '/' your shell will start at the top of the tree and look for your directory/command there. This is an absolute path. To run any executable in your current directory, use './command' - './' is just pointer to the current working directory, which should *not* be in your $PATH. Is this what you were asking? /* * John Bleichert * syborg@stny.rr.com * http://vonbek.dhs.org/latest.jpg */ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message