The which function returns the full path to some other function, if I'm not mistaken.
$ which ls # => /bin/ls
But if I wanted to the directory the function is in, how would I do that? I'm thinking of doing something like this:
$ cd $(which ls)
Obviously, that won't work because ls isn't a directory. Perhaps I'm barking up the wrong tree with which?