
Why not a program or script put “ls” after I enter cd .. or cd – ? - rajasimon
Every time I enter into folder or back I&#x27;m curious to know what inside the folder. So why not the program can inject every time when I use &quot; cd &quot;.  I know this may can&#x27;t be done. I just expecting reviews from developer perspective.
======
sglane
The folder you just changed into has 30,000 files and you're ssh'd in over a
slow network.

~~~
rajasimon
ha ha! I never expected that!

------
neeksHN
In Unix one could always write a function (not alias because it requires a
parameter) that does this - [http://askubuntu.com/questions/16106/how-can-i-
create-an-ali...](http://askubuntu.com/questions/16106/how-can-i-create-an-
alias-for-cd-and-ls). I'm sure there's equivalents in Command
Prompt/PowerShell as well.

Better for the shells' builtins to be simple and extendable - rather than be
optionated.

------
detaro
It would create a lot of noise with large folders, but if you want that
behavior you can just replace "cd" with an alias in your shell that does what
you want.

~~~
rajasimon
can you explain bit more ? how ?

------
tsukikage
cd_(){

cd $*

ls

}

alias cd=cd_

hope that helps, have a nice day

~~~
rajasimon
oh wow... this is what I exactly look for...

