Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
lib: provide a prompt function for the dirstack
Providing this additional function for prompts allows anyone using pushd/popd/dirs to navigate directory trees to quickly view their stack and find which entry they want to switch to. This degrades gracefully for anyone not using the directory stack since dirs will always display the same as \w when the stack is only one entry deep. Setting DIRSTACK_EXPAND_TILDE to true in the environment will display the directory stack with ~ expanded to the full path of the user's home directory. Setting DIRSTACK_LIMIT to any value greater than 0 will limit the display to that number of entries, though the directory stack will still contain all entries in it. The bakke theme has been tweaked to use the new function as an example. Signed-off-by: Joe MacDonald <[email protected]>
- Loading branch information