Make cd work like pushd/popd #14787
Unanswered
kas2020-commits
asked this question in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
As I've already mentioned in #13959, I have to work on an extremely large monorepo that's mounted as a network-based, pam-controlled filesystem. Because of this,
cd,openand friends are extremely painful to use because the command completion feature performs blocking I/O for suggestions.I've gotten around some of the difficulties by pre-configuring subdirs I typically work in, avoiding the blocking I/O:
but this isn't composable. Sometimes, I want to temporarily "anchor" my working dir to a specific subdir based on some buffer I've opened, then go back to the root dir once I'm done fiddling. This is very painful because I have to run
:cd ../../..to get back, which WILL do blocking I/O as I type it out, not to mention I have to count how nested I've become relative to the root every time.This can be easily solved though, if helix were to add an in-memory stack-based cd. This can either be a pair of new commands (pushd and popd) or this can be the default behavior for cd, and only add 1 new command called popd or similar. I'm not picky either way.
It seems simple to implement (I would gladly write this feature if I got some assurance that it would get merged) and would help a lot (like, a lot a lot) for moving around quickly in the editor. Would the team accept patches for this feature if I wrote it?
Beta Was this translation helpful? Give feedback.
All reactions