From owner-freebsd-questions Wed Mar 20 18:36:48 2002 Delivered-To: freebsd-questions@freebsd.org Received: from catflap.bishopston.net (catflap.bishopston.net [24.67.16.239]) by hub.freebsd.org (Postfix) with ESMTP id F1DE937B41D for ; Wed, 20 Mar 2002 18:36:40 -0800 (PST) X-Envelope-From: jamie@catflap.bishopston.net X-Envelope-To: freebsd-questions@freebsd.org Received: from catflap.bishopston.net (jamie@localhost [127.0.0.1]) by catflap.bishopston.net (8.12.1/8.12.1) with ESMTP id g2L2aean098449; Thu, 21 Mar 2002 02:36:40 GMT (envelope-from jamie@catflap.bishopston.net) Received: (from jamie@localhost) by catflap.bishopston.net (8.12.1/8.12.1/Submit) id g2L2ad36098446; Thu, 21 Mar 2002 02:36:39 GMT (envelope-from jamie) Message-Id: <200203210236.g2L2ad36098446@catflap.bishopston.net> To: David Loszewski , freebsd-questions@freebsd.org From: Jamie Jones Subject: Re: Aliasing problems In-Reply-To: <3C9937AC.3080506@metro2000.net> References: <3C9937AC.3080506@metro2000.net> X-newsgroup: muc.lists.freebsd.questions X-In-Response-To: David Loszewski X-NO-Junk: Support the ban of unsolicited junk email - http://www.cauce.org/ Date: Thu, 21 Mar 2002 02:36:39 +0000 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 In muc.lists.freebsd.questions, you wrote: > I seem to be having problems aliasing programs within just about any > startup file. If I try to do something as simple as: > > alias ls "ls -F" > > in the .xinitrc file and then try to sh it I get: > > alias: ls not found > alias: ls -F not found Firstly, the alias for you mention is for the csh/tcsh shells. The syntax for "sh" is: alias ls="ls -F" secondly, if you "sh" the file, the file will be run in a new shell, the alias will be setup, then subsequently lost when the shell exits.. You need to *source* the file, using "." instead of "sh" to load it: . ./filename > why would this be happening? this happens with anything that I try to > alias but if I try to alias it temporarily at the console it works fine. presumably, you are using the default shell on the console of "csh" ? In which case, you "source" the file with: source ./filename Cheers, jamie -- Jamie Jones http://www.bishopston.com/jamie/ --- 279 days to Christmas! Word of the day: "phototherapeutics" ---- "I'm not big, and I'm not clever. And I'm definitely not funny." ----------- The reply address on this posting expires in 7 days time. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message