我正在学习bash,所以这可能是一个非常繁琐的问题,但我不明白为什么type ls
给我输出ls is aliased to 'ls --color=auto'
,而不是ls is aliased to 'ls --color=auto'
,这正是我所期望的。
据我所知,我没有改变任何可能对此产生影响的设置。我正在Ubuntu16.04.2LTS环境中通过Vagrant运行bash命令。
发布于 2017-05-10 11:47:58
很可能是因为ls
被别名为'ls --color=auto'
。你查过你的.bashrc
了吗
grep alias .bashrc
会给你所有相关的线索。
备注:通过使用-a
选项type
,您可以获得所有可能的别名、内置程序、函数等。
type -a ls
当然也会给你/bin/ls
。
https://stackoverflow.com/questions/43891548
复制相似问题