0
Is there a way to get bash to cd to a directory by default if I just enter the directory name?
Right now what I get is:
~ bemmu$ some_directory/
-bash: some_directory/: is a directory
What I want to happen is:
~ bemmu$ some_directory/
~/some_directory bemmu$
Tried to Google a bit but couldn't find an answer. I'm on "GNU bash, version 3.2.57(1)-release (x86_64-apple-darwin15)".
I think even if it might be implemented, as the interpreter's response to all or undefined, non-existing commands, It would go against the very rules of syntax, that's why it won't be recommended anyhow. – None – 2016-10-03T05:56:22.563
3
Answered e.g. here (autocd option).
– dirkt – 2016-10-03T06:08:25.913