Clarence Verge wrote:
>
> I understand that typing it at the commandline is supposed
> to make the alias temporary,
It remains until you unalias it or logout (whichever comes
first). At any time you can execute alias (without parameter)
to see what aliases are active.
> and putting it in .bashrc will invoke it every time I logon.
Each user has his own .bashrc (in his home directory).
The changes made to .bashrc are specific to that user.
If you want something to apply to everyone, you put it
in /etc/profile.
> The problem is this: (example test sequence)
> I type dir at the commandline and get a oneline display
> that typically has /Mail in it.
OK, you are in your home directory. The only files in that
directory are hidden files, so a plain ls will not show
them. ls shows you the Mail subdirectory and nothing more.
> I type ls -la at the commandline and get a screenful of
> useful stuff.
ls -a shows you all files (including hidden ones).
ls -l gives you long output (lots of useful stuff)
> I type alias dir="ls -la" at the commandline.
> I type dir and get the original oneline display.
This means dir is aliased to plain ls. Try setting
the alias again (make sure you have the quote marks
-- an unquoted space terminates the alias). Then
execute alias (without parameter) to see if the
alias has been correctly set.
> I edit .bashrc and put that alias line in it.
> I type dir and get the original oneline display. :(
dir is still aliased to plain ls. This is probably
the same problem as above, but it would pay to check
your .bashrc to make sure that dir isn't being
re-aliased further down.
> Maybe I have to be in a particular dir ?
Nope.
> Maybe I have to be root ?
Any user can set up aliases (but they will apply only
to that user).
> Or do I have to use -al instead of -la ?
Either will do.
> How about facing east ?
South is better (preferably wearing sunglasses and holding
a banana in each hand).
> Most likely it is a problem with recall. I may recall
> incorrectly what I thought I did.
Have another try. If you are in the bash shell
(execute 'help' to be sure), then alias='ls -al'
should work.
> But I can't FIND the .bashrc (for 07) to edit it.
If you are root, your .bashrc is in /root
If you are kenny, your .bashrc is in /home/kenny
Cheers,
Steven