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

Fix reverse import order for zsh and nu #2370

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

ajesipow
Copy link

Should fix #178

Contains the following changes:

  1. Added DoubleEndedIterator implementation for UnixByteLines.

  2. Reversed import order for zsh
    I had to make some additional changes to handle commands spanning multiple lines: the previous command is prepended to the current one if it contains a line break (i.e. we need to keep the original import order for commands on multiple lines).

  3. Reversed import order for nu
    Simply reversed the order for nu. Commands spanning multiple lines do not need to be handled differently since they are stored in a single line in the history.

The import order for bash, fish and replxx seem to be correct already.
I also did not touch resh as I could not test locally since it tries importing ".resh_history.json" whereas resh seems to be storing its history in history.reshjson. So that appears to be a separate issue unless I missed something.

Checks

  • I am happy for maintainers to push small adjustments to this PR, to speed up the review cycle
  • I have checked that there are no existing pull requests for the same thing

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

Successfully merging this pull request may close these issues.

atuin import zsh imports history in reverse order?
1 participant