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

reader: Use existing search string when opening the history pager #10005

Merged
merged 1 commit into from Sep 9, 2023

Conversation

faho
Copy link
Member

@faho faho commented Sep 6, 2023

I sometimes find myself doing something like this:

  • Look for a commandline that includes "echo" (as an example)
  • Type echo, press up a few times
  • I can't immediately find what I'm looking for
  • Press ctrl-r to open up the history pager
  • It uses the current commandline as the search string, so now I'm looking for "echo foobar"

This makes it so if the search string already is in use, that's what the history-pager picks as the initial search string.

TODOs:

  • Changes to fish usage are reflected in user documentation/manpages.
  • Tests have been added for regressions fixed
  • User-visible changes noted in CHANGELOG.rst

I am entirely fine with shelving this if it gets in the way of anyone's porting. On the other hand it's pretty trivial.

I sometimes find myself doing something like this:

- Look for a commandline that includes "echo" (as an example)
- Type echo, press up a few times
- I can't immediately find what I'm looking for
- Press ctrl-r to open up the history pager
- It uses the current commandline as the search string,
  so now I'm looking for "echo foobar"

This makes it so if the search string already is in use, that's what
the history-pager picks as the initial search string.
@faho faho added this to the fish 3.7.0 milestone Sep 6, 2023
@faho faho requested a review from krobelus September 6, 2023 19:47
Copy link
Member

@krobelus krobelus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I hit this as well. Great call.

@faho faho merged commit 5b44c26 into fish-shell:master Sep 9, 2023
7 checks passed
@faho faho deleted the history-pager-use-search-string branch October 1, 2023 07:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants