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

Pull in the latest features from reedline #9207

Closed
wants to merge 2 commits into from

Conversation

sholderbach
Copy link
Member

Description

We missed to upgrade to the latest features of reedline and only upgraded publicly to the changes that fix the bracketed paste on the reedline side.

This includes a semantic change in the core of reedline on how bindings are processed and also a bigger change to the history to support ignoring of entries for the history.
If you just release the current reedline main we would not enable history exclusion. This requires the second commit of this PR.

Commits

We may want to only merge the first (Doing a branched of release of just what we already pinned in Cargo.lock seems like extraordinary effort)

  • Update to most recent reedline state
  • Enable history exclusion with preceding SPACE

User-Facing Changes

If we land the first commit will change the behavior of keybindings that were previously ignored as they tried to capture a potentially printable character that was directly inserted into the buffer. Now more bindings are possible:

  • Binding a printable character in the inserting modes (vi_insert and emacs).
  • Use of Ctrl-Alt combinations that were previously ignored to make sure AltGr characters (found on many European keyboards) can properly be inserted.

If we land the second commit before the release will ignore all manually entered lines starting with the space from addition to the history. You can still recall the last entry by pressing up arrow once even if it started with a space but it will not be stored in the history file.

Tests + Formatting

The newest reedline behavior wasn't really tested by a wider base of users in the full nushell context.

After Submitting

This includes the changes for history exclusion only on the reedline
side, needs explicit enabling on the consumer side.

Also changes the behavior of keybindings with modifiers that previously
where unsupported. Now it is possible to bind keys without a modifier or
that use Ctrl+Alt in directly inserting modes.
This feature was introduced by:
nushell/reedline#566

Enabled and set the prefix to a hard-coded space
@codecov
Copy link

codecov bot commented May 16, 2023

Codecov Report

Merging #9207 (20b6e6b) into main (bf86cd5) will decrease coverage by 0.01%.
The diff coverage is 0.00%.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #9207      +/-   ##
==========================================
- Coverage   68.92%   68.91%   -0.01%     
==========================================
  Files         635      635              
  Lines      102041   102042       +1     
==========================================
- Hits        70332    70327       -5     
- Misses      31709    31715       +6     
Impacted Files Coverage Δ
crates/nu-cli/src/repl.rs 3.34% <0.00%> (-0.01%) ⬇️

... and 2 files with indirect coverage changes

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.

None yet

1 participant