{"id":13437433,"url":"https://github.com/fcsonline/tmux-thumbs","last_synced_at":"2025-05-15T03:05:36.407Z","repository":{"id":38331309,"uuid":"169139591","full_name":"fcsonline/tmux-thumbs","owner":"fcsonline","description":"A lightning fast version of tmux-fingers written in Rust, copy/pasting tmux like vimium/vimperator","archived":false,"fork":false,"pushed_at":"2024-04-20T05:12:22.000Z","size":217,"stargazers_count":960,"open_issues_count":41,"forks_count":65,"subscribers_count":10,"default_branch":"master","last_synced_at":"2025-05-15T03:05:34.873Z","etag":null,"topics":["rust","tmux","tmux-plugins","vimium","vimperator"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fcsonline.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-02-04T19:56:14.000Z","updated_at":"2025-05-14T05:01:58.000Z","dependencies_parsed_at":"2024-10-30T14:15:11.413Z","dependency_job_id":null,"html_url":"https://github.com/fcsonline/tmux-thumbs","commit_stats":{"total_commits":238,"total_committers":26,"mean_commits":9.153846153846153,"dds":0.2184873949579832,"last_synced_commit":"ae91d5f7c0d989933e86409833c46a1eca521b6a"},"previous_names":[],"tags_count":15,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fcsonline%2Ftmux-thumbs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fcsonline%2Ftmux-thumbs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fcsonline%2Ftmux-thumbs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fcsonline%2Ftmux-thumbs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fcsonline","download_url":"https://codeload.github.com/fcsonline/tmux-thumbs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254264765,"owners_count":22041793,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["rust","tmux","tmux-plugins","vimium","vimperator"],"created_at":"2024-07-31T03:00:56.942Z","updated_at":"2025-05-15T03:05:36.387Z","avatar_url":"https://github.com/fcsonline.png","language":"Rust","readme":"# tmux-thumbs\n\n[![Build Status](https://github.com/fcsonline/tmux-thumbs/workflows/Rust/badge.svg)](https://github.com/fcsonline/tmux-thumbs/actions)\n[![dependency status](https://deps.rs/repo/github/fcsonline/tmux-thumbs/status.svg)](https://deps.rs/repo/github/fcsonline/tmux-thumbs)\n[![Coverage Status](https://coveralls.io/repos/github/fcsonline/tmux-thumbs/badge.svg?branch=master)](https://coveralls.io/github/fcsonline/tmux-thumbs?branch=master)\n[![Maintenance](https://img.shields.io/badge/maintenance-actively%20maintained-brightgreen.svg)](https://deps.rs/repo/github/fcsonline/tmux-thumbs)\n[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)](./LICENSE)\n\nA lightning fast version of [tmux-fingers](https://github.com/Morantron/tmux-fingers) written in [Rust](https://www.rust-lang.org/) for copy pasting with vimium/vimperator like hints.\n\n## Usage\n\nPress ( \u003ckbd\u003eprefix\u003c/kbd\u003e + \u003ckbd\u003eSpace\u003c/kbd\u003e ) to highlight in you current tmux\nvisible pane all text that match specific patterns. Then press the highlighted\nletter hint to yank the text in your tmux buffer.\n\n### Matched patterns\n\n- File paths\n- File in diff\n- Git SHAs\n- IPFS CID's\n- Colors in hex\n- Numbers ( 4+ digits )\n- Hex numbers\n- Markdown urls\n- IPv4, IPv6 addresses\n- Docker images\n- kubernetes resources\n- UUIDs\n\nThese are the list of matched patterns that will be highlighted by default. If\nyou want to highlight a pattern that is not in this list you can add one or\nmore with `--regexp` parameter.\n\n## Demo\n\n[![demo](https://asciinema.org/a/232775.png?ts=1)](https://asciinema.org/a/232775?autoplay=1)\n\n## Using Tmux Plugin Manager\n\nYou can add this line to your list of [TPM](https://github.com/tmux-plugins/tpm) plugins in `.tmux.conf`:\n\n```\nset -g @plugin 'fcsonline/tmux-thumbs'\n\nrun-shell ~/.tmux/plugins/tmux-thumbs/tmux-thumbs.tmux\n```\n\nTo be able to install the plugin just hit \u003ckbd\u003eprefix\u003c/kbd\u003e + \u003ckbd\u003eI\u003c/kbd\u003e. You should now be able to use\nthe plugin!\n\n## Installation checking out the source code\n\n`tmux-thumbs` is written in Rust. You will need `rustc` version 1.35.0 or higher. The\nrecommended way to install Rust is from the official [download page](https://rustup.rs/).\n\nClone the repo:\n\n```\ngit clone https://github.com/fcsonline/tmux-thumbs ~/.tmux/plugins/tmux-thumbs\n```\n\nCompile it with [cargo](https://doc.rust-lang.org/cargo/getting-started/installation.html):\n\n```\ncd ~/.tmux/plugins/tmux-thumbs\ncargo build --release\n```\n\nSource it in your `.tmux.conf`:\n\n```\nrun-shell ~/.tmux/plugins/tmux-thumbs/tmux-thumbs.tmux\n```\n\nReload TMUX conf by running:\n\n```\ntmux source-file ~/.tmux.conf\n```\n\n## Configuration\n\nIf you want to customize how is shown your tmux-thumbs hints those all available\nparameters to set your perfect profile.\n\nNOTE: for changes to take effect, you'll need to source again your `.tmux.conf` file.\n\n* [@thumbs-key](#thumbs-key)\n* [@thumbs-alphabet](#thumbs-alphabet)\n* [@thumbs-reverse](#thumbs-reverse)\n* [@thumbs-unique](#thumbs-unique)\n* [@thumbs-position](#thumbs-position)\n* [@thumbs-regexp-N](#thumbs-regexp-N)\n* [@thumbs-command](#thumbs-command)\n* [@thumbs-upcase-command](#thumbs-upcase-command)\n* [@thumbs-multi-command](#thumbs-multi-command)\n* [@thumbs-bg-color](#thumbs-bg-color)\n* [@thumbs-fg-color](#thumbs-fg-color)\n* [@thumbs-hint-bg-color](#thumbs-hint-bg-color)\n* [@thumbs-hint-fg-color](#thumbs-hint-fg-color)\n* [@thumbs-select-fg-color](#thumbs-select-fg-color)\n* [@thumbs-select-bg-color](#thumbs-select-bg-color)\n* [@thumbs-multi-fg-color](#thumbs-multi-fg-color)\n* [@thumbs-multi-bg-color](#thumbs-multi-bg-color)\n* [@thumbs-contrast](#thumbs-contrast)\n* [@thumbs-osc52](#thumbs-osc52)\n\n### @thumbs-key\n\n`default: space`\n\nChoose which key is used to enter in thumbs mode.\n\nFor example:\n\n```\nset -g @thumbs-key F\n```\n\nIf you want to customize the way how `tmux-thumbs` is triggered, you can always\nbind whatever key to `thumbs-pick` command. For example:\n\n```\nbind-key \\; thumbs-pick\n```\n\n### @thumbs-alphabet\n\n`default: qwerty`\n\nChoose which set of characters is used to build hints. Review all [available alphabets](#Alphabets)\n\nFor example:\n\n```\nset -g @thumbs-alphabet dvorak-homerow\n```\n\n### @thumbs-reverse\n\n`default: disabled`\n\nChoose in which direction you want to assign hints. Useful to get shorter hints closer to the cursor.\n\nFor example:\n\n```\nset -g @thumbs-reverse enabled\n```\n\n### @thumbs-unique\n\n`default: disabled`\n\nChoose if you want to assign the same hint for the same matched strings.\n\nFor example:\n\n```\nset -g @thumbs-unique enabled\n```\n\n### @thumbs-position\n\n`default: left`\n\nChoose where do you want to show the hint in the matched string. Options (left, right, off_left, off_right).\n\nFor example:\n\n```\nset -g @thumbs-position right\n```\n\n### @thumbs-regexp-N\n\nAdd extra patterns to match. This parameter can have multiple instances.\n\nFor example:\n\n```\nset -g @thumbs-regexp-1 '[\\w-\\.]+@([\\w-]+\\.)+[\\w-]{2,4}' # Match emails\nset -g @thumbs-regexp-2 '[a-f0-9]{2}:[a-f0-9]{2}:[a-f0-9]{2}:[a-f0-9]{2}:[a-f0-9]{2}:[a-f0-9]{2}:' # Match MAC addresses\nset -g @thumbs-regexp-3 'Vlan\\d+' # match Vlan interface on network devices\nset -g @thumbs-regexp-4 \"Vlan\\\\d+\" # alternative method of defining regexp\nset -g @thumbs-regexp-5 Vlan\\\\d+ # alternative method of defining regexp\n```\n\n### @thumbs-command\n\n`default: 'tmux set-buffer -- {} \u0026\u0026 tmux display-message \\\"Copied {}\\\"'`\n\nChoose which command execute when you press a hint. `tmux-thumbs` will replace `{}` with the picked hint.\n\nFor example:\n\n```\nset -g @thumbs-command 'echo -n {} | pbcopy'\n```\n\n### @thumbs-upcase-command\n\n`default: 'tmux set-buffer -- {} \u0026\u0026 tmux paste-buffer \u0026\u0026 tmux display-message \\\"Copied {}\\\"'`\n\nChoose which command execute when you press a upcase hint. `tmux-thumbs` will replace `{}` with the picked hint.\n\nFor example:\n\n```\nset -g @thumbs-upcase-command 'echo -n {} | pbcopy'\n```\n\n### @thumbs-multi-command\n\n`default: 'tmux set-buffer -- {} \u0026\u0026 tmux paste-buffer \u0026\u0026 tmux send-keys ' ' \u0026\u0026 tmux display-message \\\"Copied multiple items!\\\"'`\n\nChoose which command execute when you select multiple items. `tmux-thumbs` will replace `{}` with the picked hint for each one.\n\nFor example:\n\n```\nset -g @thumbs-multi-command 'echo -n {}'\n```\n\n### @thumbs-bg-color\n\n`default: black`\n\nSets the background color for matches\n\nFor example:\n\n```\nset -g @thumbs-bg-color blue\n```\n\n### @thumbs-fg-color\n\n`default: green`\n\nSets the foreground color for matches\n\nFor example:\n\n```\nset -g @thumbs-fg-color green\n```\n\n### @thumbs-hint-bg-color\n\n`default: black`\n\nSets the background color for hints\n\nFor example:\n\n```\nset -g @thumbs-hint-bg-color blue\n```\n\n### @thumbs-hint-fg-color\n\n`default: yellow`\n\nSets the foreground color for hints\n\nFor example:\n\n```\nset -g @thumbs-hint-fg-color green\n```\n\n### @thumbs-select-fg-color\n\n`default: blue`\n\nSets the foreground color for selection\n\nFor example:\n\n```\nset -g @thumbs-select-fg-color red\n```\n\n### @thumbs-select-bg-color\n\n`default: black`\n\nSets the background color for selection\n\nFor example:\n\n```\nset -g @thumbs-select-bg-color red\n```\n\n### @thumbs-multi-fg-color\n\n`default: yellow`\n\nSets the foreground color for multi selected item\n\nFor example:\n\n```\nset -g @thumbs-multi-fg-color green\n```\n\n### @thumbs-multi-bg-color\n\n`default: black`\n\nSets the background color for multi selected item\n\nFor example:\n\n```\nset -g @thumbs-multi-bg-color red\n```\n\n### @thumbs-contrast\n\n`default: 0`\n\nDisplays hint character in square brackets for extra visibility.\n\nFor example:\n\n```\nset -g @thumbs-contrast 1\n```\n\n### @thumbs-osc52\n\n`default: 0`\n\nIf this is set to `1`, `tmux-thumbs` will print a OSC52 copy escape sequence when you select a match, in addition to running the pick command. This sequence, in terminals that support it (e.g. iTerm), allows the content to be copied into the system clipboard in addition to the tmux copy buffer.\n\nFor example:\n\n```\nset -g @thumbs-osc52 1\n```\n\n#### Colors\n\nThis is the list of predefined colors:\n\n- black\n- red\n- green\n- yellow\n- blue\n- magenta\n- cyan\n- white\n- default\n\nThere is also support for using hex colors in the form of `#RRGGBB`.\n\n#### Alphabets\n\nThis is the list of available alphabets:\n\n- `numeric`: 1234567890\n- `abcd`: abcd\n- `qwerty`: asdfqwerzxcvjklmiuopghtybn\n- `qwerty-homerow`: asdfjklgh\n- `qwerty-left-hand`: asdfqwerzcxv\n- `qwerty-right-hand`: jkluiopmyhn\n- `azerty`: qsdfazerwxcvjklmuiopghtybn\n- `azerty-homerow`: qsdfjkmgh\n- `azerty-left-hand`: qsdfazerwxcv\n- `azerty-right-hand`: jklmuiophyn\n- `qwertz`: asdfqweryxcvjkluiopmghtzbn\n- `qwertz-homerow`: asdfghjkl\n- `qwertz-left-hand`: asdfqweryxcv\n- `qwertz-right-hand`: jkluiopmhzn\n- `dvorak`: aoeuqjkxpyhtnsgcrlmwvzfidb\n- `dvorak-homerow`: aoeuhtnsid\n- `dvorak-left-hand`: aoeupqjkyix\n- `dvorak-right-hand`: htnsgcrlmwvz\n- `colemak`: arstqwfpzxcvneioluymdhgjbk\n- `colemak-homerow`: arstneiodh\n- `colemak-left-hand`: arstqwfpzxcv\n- `colemak-right-hand`: neioluymjhk\n\n## Extra features\n\n- **Arrow navigation:** You can use the arrows to move around between all matched items.\n- **Auto paste:** If your last typed hint character is uppercase, you are going to pick and paste the desired hint.\n\n### Multi selection\n\nIf you want to enable the capability to choose multiple matches, you have to\npress \u003ckbd\u003eSpace\u003c/kbd\u003e. Then, choose the matches with highlighted hints or\n\u003ckbd\u003eEnter\u003c/kbd\u003e (moving with cursors) and then \u003ckbd\u003eSpace\u003c/kbd\u003e again to\noutput all of them.\n\nIf you run standalone `thumbs` with multi selection mode (-m) you will be able to choose multiple hints pressing the desired letter and \u003ckbd\u003eSpace\u003c/kbd\u003e to finalize the selection.\n\n## Tmux compatibility\n\nThis is the known list of versions of `tmux` compatible with `tmux-thumbs`:\n\n| Version | Compatible |\n|:-------:|:----------:|\n|   3.0a  |     ✅     |\n|   2.9a  |     ✅     |\n|   2.8   |      ❓    |\n|   2.7   |      ❓    |\n|   2.6   |     ✅     |\n|   2.5   |      ❓    |\n|   2.4   |      ❓    |\n|   2.3   |      ❓    |\n|   1.8   |      ❓    |\n|   1.7   |      ❓    |\n\nIf you can check hat `tmux-thumbs` is or is not compatible with some specific version of `tmux`, let me know.\n\n## Standalone `thumbs`\n\nThis project started as a `tmux` plugin but after reviewing it with some\nfriends we decided to explore all the possibilities of decoupling thumbs from\n`tmux`. You can install it with a simple command:\n\n```\ncargo install thumbs\n```\n\nAnd those are all available options:\n\n```\nthumbs 0.7.1\nA lightning fast version copy/pasting like vimium/vimperator\n\nUSAGE:\n    thumbs [FLAGS] [OPTIONS]\n\nFLAGS:\n    -c, --contrast    Put square brackets around hint for visibility\n    -h, --help        Prints help information\n    -m, --multi       Enable multi-selection\n    -r, --reverse     Reverse the order for assigned hints\n    -u, --unique      Don't show duplicated hints for the same match\n    -V, --version     Prints version information\n\nOPTIONS:\n    -a, --alphabet \u003calphabet\u003e                          Sets the alphabet [default: qwerty]\n        --bg-color \u003cbackground_color\u003e                  Sets the background color for matches [default: black]\n        --fg-color \u003cforeground_color\u003e                  Sets the foregroud color for matches [default: green]\n    -f, --format \u003cformat\u003e\n            Specifies the out format for the picked hint. (%U: Upcase, %H: Hint) [default: %H]\n\n        --hint-bg-color \u003chint_background_color\u003e        Sets the background color for hints [default: black]\n        --hint-fg-color \u003chint_foreground_color\u003e        Sets the foregroud color for hints [default: yellow]\n    -p, --position \u003cposition\u003e                          Hint position [default: left]\n    -x, --regexp \u003cregexp\u003e...                           Use this regexp as extra pattern to match\n        --select-bg-color \u003cselect_background_color\u003e    Sets the background color for selection [default: black]\n        --select-fg-color \u003cselect_foreground_color\u003e    Sets the foreground color for selection [default: blue]\n        --multi-bg-color \u003cmulti_background_color\u003e      Sets the background color for a multi selected item [default: black]\n        --multi-fg-color \u003cmulti_foreground_color\u003e      Sets the foreground color for a multi selected item [default: cyan]\n    -t, --target \u003ctarget\u003e                              Stores the hint in the specified path\n```\n\n\nIf you want to enjoy terminal hints, you can do things like this without `tmux`:\n\n```\n\u003e alias pick='thumbs -u -r | xsel --clipboard -i'\n\u003e git log | pick\n```\n\nOr multi selection:\n\n```\n\u003e git log | thumbs -m\n1df9fa69c8831ac042c6466af81e65402ee2a007\n4897dc4ecbd2ac90b17de95e00e9e75bb540e37f\n```\n\nStandalone `thumbs` has some similarities to [FZF](https://github.com/junegunn/fzf).\n\n## Background\n\nAs I said, this project is based in [tmux-fingers](https://github.com/Morantron/tmux-fingers). Morantron did an extraordinary job, building all necessary pieces in Bash to achieve the text picker behaviour. He only deserves my gratitude for all the time I have been using [tmux-fingers](https://github.com/Morantron/tmux-fingers).\n\nDuring a [Fosdem](https://fosdem.org/) conf, we had the idea to rewrite it to another language. He had these thoughts many times ago but it was hard to start from scratch. So, we decided to start playing with Node.js and [react-blessed](https://github.com/Yomguithereal/react-blessed), but we detected some unacceptable latency when the program booted. We didn't investigate much about this latency.\n\nDuring those days another alternative appeared, called [tmux-picker](https://github.com/RTBHOUSE/tmux-picker), implemented in python and reusing many parts from [tmux-fingers](https://github.com/Morantron/tmux-fingers). It was nice, because it was fast and added original terminal color support.\n\nI was curious to know if this was possible to be written in [Rust](https://www.rust-lang.org/), and soon I realized that was something doable. The ability to implement tests for all critic parts of the application give you a great confidence about it. On the other hand, Rust has an awesome community that lets you achieve this kind of project in a short period of time.\n\n## Roadmap\n\n- [X] Support multi selection\n- [X] Decouple `tmux-thumbs` from `tmux`\n- [ ] Code [Kitty](https://github.com/kovidgoyal/kitty) plugin, now that `thumbs` can run standalone\n\n## Troubleshooting\n\n`tmux-thumbs` must work lighting fast. If you are facing a slow performance capturing the screen hints try to configure Tmux with these settings:\n\n```\nset -g visual-activity off\nset -g visual-bell off\nset -g visual-silence on\n```\n\nYou can read a bit more about this issue here: https://github.com/fcsonline/tmux-thumbs/issues/88\n\nEvery time I use `tmux-thumbs`, dead panes are created. Just review if you have\nthis setting on:\n\n```\nset -g remain-on-exit on\n```\n\nYou can read a bit more about this issue here: https://github.com/fcsonline/tmux-thumbs/issues/84\n\n## Donations\n\nIf you appreciate all the job done in this project, a small donation is always welcome:\n\n[![\"Buy Me A Coffee\"](https://www.buymeacoffee.com/assets/img/custom_images/orange_img.png)](https://www.buymeacoffee.com/fcsonline)\n\n## Contribute\n\nThis project started as a side project to learn Rust, so I'm sure that is full\nof mistakes and areas to be improve. If you think you can tweak the code to\nmake it better, I'll really appreciate a pull request. ;)\n\n# License\n\n[MIT](https://github.com/fcsonline/tmux-thumbs/blob/master/LICENSE)\n","funding_links":["https://www.buymeacoffee.com/fcsonline"],"categories":["Applications","Rust","应用程序 Applications","应用","应用 Applications","Plugins"],"sub_categories":["Utilities","公用事业公司 Utilities","实用","公用事业 Utilities"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffcsonline%2Ftmux-thumbs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffcsonline%2Ftmux-thumbs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffcsonline%2Ftmux-thumbs/lists"}