OSC52 support was implemented before two major refactors in tmux-thubs:
- Decouple tmux-thumbs from tmux
- Removal of rustbox with termion
I'm not sure if is the right decision, but I moved the arguments to
swapper land because it looks like more tmux related. If it makes sense
for other terminals to support this we can move it back.
The question we need to answer here if it makes sense for standalone `thumbs`:
```
cat sample/test1 | ./target/release/thumbs --osc52
```
Currently I can only get the copied content in the tmux copy buffer, not in the
system clipboard. This commit adds an option to print the copied text as a
OSC52 copy escape sequence, which in supported terminals (tested in iTerm) will
be copied to the system clipboard.
The regular expression describing the tmux user options expects to find
quotes around the value. However, in at least tmux 3.0a the
`show-options -g` command doesn't display quotes around the values,
which means the regex fails.
For example, the current regex will fail to find these user options:
$ tmux -V
tmux 3.0a
$ tmux show -g | grep -E "@thumbs"
@thumbs-bg-color default
@thumbs-fg-color green
@thumbs-hint-bg-color default
@thumbs-hint-fg-color blue
@thumbs-select-bg-color default
@thumbs-select-fg-color green
Make the quotes optional so that these options are picked up.
Fixes#33
Before this commit `command` and `upcase_command` where executed if you
pressed an uppercase key. This can force the user to have a innocuous
lower case command if they want to execute together.
Now they can be totally independent.
Add an option to surround the hint character with square brackets
(for example `[a]` rather than `a`). This is the equivalent to the
following `tmux-fingers` configuration option [1] and is useful to make
the hint more visible:
```
set -g @fingers-compact-hints 0
```
[1] - https://github.com/Morantron/tmux-fingers#fingers-compact-hints
Signed-off-by: James O. D. Hunt <jamesodhunt@gmail.com>