Open jovanbulck opened 9 years ago
I don't think I get it. You mean that you want to have a list of recent directories to cycle through?
See issue #34:
Quote:
Normally, cd -
gets you in the previous directory.
Expected behaviour:
$ pwd
/etc/apt
$ cd /mnt/Data
$ pwd
/mnt/Data
$ cd -
$ pwd
/etc/apt
Actual behaviour:
$ pwd
/etc/apt
$ cd /mnt/Data
$ pwd
/mnt/Data
$ cd -
[DEBUG: You entered: 'cd -']
[DEBUG: readcmd: cmd 'cd -' expanded to 'cd -']
[DEBUG: alias: input resolved to: 'cd -']
jsh: cd: No such file or directory
[DEBUG: built-in: executed 'cd']
[DEBUG: freeing comd struct for 'cd']
[DEBUG: parseexpr: expr evaluated with return value 1]
[DEBUG: readcmd: freeing memory for: 'cd']
$ pwd
/mnt/Data
See issue #51 for further discussion
IDEA: push the cwd on a stack on each call to cd and write a simple built_in to e.g. pop the top cwd and cd into it; have a user_defined number of directories to remember (eg via an environment variable?)
--> would be really usefull and probably also easy to implement...
(I think something familiar is done in bash and zsh.)