-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes #1
- Loading branch information
Showing
1 changed file
with
28 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Search kitten for kitty | ||
|
||
[Kitten](https://sw.kovidgoyal.net/kitty/#kittens) for the [kitty terminal emulator](https://sw.kovidgoyal.net/kitty/) providing live incremental search in the terminal history. | ||
|
||
![Demo](https://user-images.githubusercontent.com/601966/78996982-09c42c80-7b46-11ea-9cb2-d338b846ab87.gif) | ||
|
||
## Installation | ||
|
||
Place the two `.py` files in this repo (`search.py` and `scroll_mark.py`) in the same directory as `kitty.conf`. | ||
|
||
Map a key to launch the kitten. E.g. for `kitty_mod+/` add this to `kitty.conf`: | ||
|
||
``` | ||
map kitty_mod+/ launch --allow-remote-control kitty +kitten search.py @active-kitty-window-id | ||
``` | ||
|
||
## Usage | ||
|
||
Pressing the key you mapped will open a window where you can type your search. The search is performed immediately as you type each key, however currently it does not scroll to a match automatically if it is outside of the current content shown. | ||
|
||
These keys can be used to control the kitten: | ||
|
||
- Up/down arrow: Scroll to previous/next match | ||
- Tab: Switch between literal match and regex match | ||
- Ctrl-u: Clear the query | ||
- Ctrl-a/e: Go to the beginning/end of the query | ||
- Enter: Exit the kitten and keep the current scroll position | ||
- Esc: Exit the kitten and scroll to the bottom of the history |