Re: profile.d [was Re: UMASK 002 or 022?]
Quoting Sami Haahtinen <ressu@uusikaupunki.fi>:
> On Thu, Jun 08, 2000 at 10:21:21AM +0100, Andrew Stribblehill wrote:
> > > alias('ls', 'ls --color=auto -F')
> >
> > define(`set', `export $1=$2')
> > define(`alias', ``alias' $1=$2')
> > include(`.environment')
> >
> > One problem I /can/ see with this is that m4 would need its
> > priority elevating if it were to be used in this way. But hey,
> > *everyone* uses m4, don't they?
>
> Isn't that a bit slow? considering that every time you log in, the files
> are parsed.
No, you have to run commands like:
$ m4 < .bash_profile.m4 > .bash_profile
etc. Of course, I put that into a trivial makefile:
--------------------8<--------------------Makefile
all: .bash_profile .cshrc
%: %.m4 .environment
m4 < $< > $@ # This line starts with a tab!
-------------------->8--------------------
Thinking about it, I could put a make incantation into my
.{bash_,}login files, but I tend to remember when I've changed
such a file.
Cheerio,
Andrew.
Reply to: