🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.bash.bug
Article #491

[idallen@watcgl: bash aliases not transitive?!]

#491
From: Brian Fox
Date: Wed, 23 Aug 1989 20:37
40 lines
1733 bytes
   Date: Wed, 23 Aug 89 15:38:47 EDT
   From: Andy Wai <accwai@watmath.waterloo.edu>

   > Date: Wed, 23 Aug 89 09:50:51 PDT
   > From: bfox@aurel.caltech.edu (Brian Fox)
   > Reply-To: bfox@aurel.caltech.edu
   > 
   >    Date: Wed, 23 Aug 89 11:45:28 EDT
   >    From: Andy Wai <accwai@watmath.waterloo.edu>
   > 
   >    > Date: Tue, 22 Aug 89 20:35:20 EDT
   >    > From: "Ian! D. Allen [CGL]" <idallen@watcgl>
   >    > To: accwai@watmath
   >    > Subject: bash aliases not transitive?!
   >    >
   >    >     bash$ alias a=b
   >    >     bash$ alias b=date
   >    >     bash$ a
   >    >     b: commmand not found
   >    > [...]
   > 
   > Aliases are only expanded when they are in the position of a command
   > word, or if they follow an alias whose expansion ends in a space.
   > 
   > Brian

   I think alias expansion should be transitive.  In the above example,
   'a' should be expanded into 'date'.  In fact, that's what ksh does.  Is
   there any reason why this behavior is not desirable?

   Andy Wai

You keep using the word 'transitive' when in actuality you want aliases
to be expanded purely based on textual matches, irregardless of
location.

Am I making a correct assumption?

Brian
Technical Details
Message-ID: <8908232037.AA02389@aurel.caltech.edu>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!watmath!uunet!tut.cis.ohio-state.edu!AUREL.CALTECH.EDU!bfox
References: <8908231938.AA03422@watmath.waterloo.edu>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!watmath!uunet!tut.cis.ohio-state.edu!AUREL.CALTECH.EDU!bfox
From: bfox@AUREL.CALTECH.EDU (Brian Fox)
Newsgroups: gnu.bash.bug
Subject: [idallen@watcgl: bash aliases not transitive?!]
Message-ID: <8908232037.AA02389@aurel.caltech.edu>
Date: 23 Aug 89 20:37:07 GMT
References: <8908231938.AA03422@watmath.waterloo.edu>
Sender: daemon@tut.cis.ohio-state.edu
Reply-To: bfox@aurel.caltech.edu
Distribution: gnu
Organization: GNUs Not Usenet
Lines: 40