Skip to content
Myr

Fix zsh history widget when `sh_glob` option is on (#4714)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Fixes #4712. The CTRL-R history widget failed in zsh when [zsh's `sh_glob` option][0] was on. This fixes that by disabling the option locally, like we disable other options. [0]: https://zsh.sourceforge.io/Doc/Release/Options.html#:~:text=SH%5FGLOB,ksh%2E

authored by Evan Hahn · committed by GitHub · parent 26de195 · Browse files · 2 files+2 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

2 files+2 added−1 removed

  • tests:+1 added−0 removed
  • other:+1 added−1 removed

2 files+2 added−1 removed

modified:shell/key-bindings.zsh+1 added-1 removed
modified:test/test_shell_integration.rb+1 added
918 unmodified lines
919 tmux.until { |lines| assert_equal '1 foobar', lines[-1] }920 end921922 test_perl_and_awk 'ctrl_r_multiline_index_collision' do923 tmux.send_keys 'setopt sh_glob', :Enter924 # Leading number in multi-line history content is not confused with index925 prepare_ctrl_r_test926 tmux.send_keys "'line 1"927 tmux.until { |lines| assert_equal 1, lines.match_count }
129 unmodified lines