Add this code into your .bashrc. It will make your ordinary cd able to cache recent accessed directory.