search_command_line_history_using_glob_pattern_matching
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
search_command_line_history_using_glob_pattern_matching [2022/05/05 13:08] – [Situation] admin | search_command_line_history_using_glob_pattern_matching [2022/05/05 13:09] (current) – [System Information] admin | ||
---|---|---|---|
Line 33: | Line 33: | ||
==== Solution ==== | ==== Solution ==== | ||
Add the following lines to ~/.zshrc. | Add the following lines to ~/.zshrc. | ||
+ | <WRAP indent> | ||
< | < | ||
# Use glob patterns when using ctrl-r | # Use glob patterns when using ctrl-r | ||
Line 44: | Line 45: | ||
fi | fi | ||
</ | </ | ||
+ | </ | ||
After this | After this | ||
+ | <WRAP indent> | ||
< | < | ||
ctrl-r | ctrl-r | ||
cd*rutils | cd*rutils | ||
</ | </ | ||
+ | </ | ||
will match commands where cd is followed by rutils. | will match commands where cd is followed by rutils. | ||
Line 55: | Line 59: | ||
Tested this tip using zsh 5.0.7 on a machine running Debian Jessie. | Tested this tip using zsh 5.0.7 on a machine running Debian Jessie. | ||
+ | <WRAP indent> | ||
< | < | ||
% dpkg -l zsh | grep ^ii | % dpkg -l zsh | grep ^ii | ||
ii zsh 5.0.7-5 | ii zsh 5.0.7-5 | ||
</ | </ | ||
+ | </ | ||
tags | reverse search using partial matches shell, reverse search using multiple words shell, use glob patterns in ctrl-r | tags | reverse search using partial matches shell, reverse search using multiple words shell, use glob patterns in ctrl-r |
search_command_line_history_using_glob_pattern_matching.1651756124.txt.gz · Last modified: 2022/05/05 13:08 by admin