Reputation: 291
When I perform ls
in bash, I always see too many *.pyc
files. Is there any way to hide these files?
Upvotes: 27
Views: 5579
Reputation: 4961
This way lies the dark side, but you could force ls
to never show them by adding something like
alias ls='ls --hide="*.pyc"'
to your .bashrc
. ls
will reveal the hidden files if you use -a
or -A
.
However, I would recommend just ignoring them in your head, or running this version of ls
when you really don't want to see them.
Upvotes: 33