BBS水木清华站∶精华区
发信人: ajahn@spd.dsccc.com (Alfredo Jahn), 看板: LX.misc
标 题: Re: Can't use 'ls' command
发信站: DSC Communications Corporation, Plano, Texa (Fri Jul 25 06:27:05 1997)
转信站: sobee!netnews.ntu!news.mcu!news.cs.nthu!UUserv.Net.tw!aidebbs!news.yzi
JHB NIJHOF (nijhojhb@aston.ac.uk) wrote:
∶ Irene ah! (irene-ah@geocities.com) wrote:
∶ : I installed Red Hat Linux release 4.0
∶ : Kernel 2.0.18 on an i386
∶ :
∶ : why i using 'ls' with an error as:
∶ :
∶ : /bin/ls: unrecognized option '--8bit'
∶ : Try '/bin/ls --help' for more information.
∶ :
∶ : use other command is ok,
∶ : i try cd to /bin then use 'ls' also with same problem
∶ : but use '/bin/ls' is ok.
∶ :
∶ : pls help me, TKS!!!
∶ You have got 'ls' aliased to '/bin/ls --8bit',
∶ in your personal or (probably) global shell initialisation script.
∶ By typing 'alias ls' you can find out what it is aliased to exactly;
∶ look for that string in one of:
∶ /etc/profile ; ~/.profile ; ~/.bashrc (for bash);
∶ ~/.login ; ~/.cshrc (for csh).
∶ Removing the 'alias ls' line from the script in question
∶ should do the trick, but only after you log in again (to get rid of
∶ it in this shell, type 'unalias ls' ; that works for bash, at least).
A good trick to know is using the "\" in front of a command will
over-ride an alias. For example, I alias "rm" to "rm -i" so that
it queries me when I delete something. Sometimes I know what I want
and I don't want to be queried for every file, especially when I
want to do an "rm *" in a directory which contains lots of files.
So, what you can do is: "\rm *" and it skips any alias you might
have set up. So, to solve your "ls" problem (which I'm sure you've
already resolved...) use the following command:
\ls
∶ Jeroen Nijhof
--
Alfredo Jahn
ajahn@spd.dsccc.com
http://www.wn.com/per/alfredo/
BBS水木清华站∶精华区