Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Browsing history for comint, eshell, shell #49

Closed
leungbk opened this issue Dec 10, 2020 · 5 comments
Closed

Browsing history for comint, eshell, shell #49

leungbk opened this issue Dec 10, 2020 · 5 comments

Comments

@leungbk
Copy link

leungbk commented Dec 10, 2020

It would be nice if consult had functions for browsing their respective history files.

@minad
Copy link
Owner

minad commented Dec 10, 2020

I think consult-history does what you want? It was just added yesterday!

@minad minad closed this as completed Dec 10, 2020
@leungbk
Copy link
Author

leungbk commented Dec 10, 2020

Thanks @minad, I did not notice that.

Would you be interested in a PR like abo-abo/swiper@69fedaa? The purpose is to add support for the C-c C-x commands in comint and eshell.

@minad
Copy link
Owner

minad commented Dec 10, 2020

@leungbk Can you describe please what you want to do? I took only a quick look to the link, but it is not immediately obvious.

@leungbk
Copy link
Author

leungbk commented Dec 10, 2020

If my eshell history contains:

echo old
echo newer
echo newest

Right now, if I call consult-history, then select echo old and hit RET, there is no way to quickly retrieve its successor, echo newer in the history list; I would have to either call consult-history again or mash M-p until finding it.

The comint-like modes all contain a command bound to C-c C-x for retrieving the successor; in eshell it's called eshell-get-next-from-history.

Right now, consult-history does not do the bookkeeping required to update the information used by eshell-get-next-from-history. The commit I posted above did that for counsel's relevant commands, and I'd now like to write something analogous here in consult.

@minad
Copy link
Owner

minad commented Dec 10, 2020

@leungbk Ok, I see. This sounds good! Looking forward to a PR!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants