{"id":13898164,"url":"https://github.com/girishji/vimbits","last_synced_at":"2026-02-09T11:33:04.419Z","repository":{"id":242846525,"uuid":"810732478","full_name":"girishji/vimbits","owner":"girishji","description":"Curated Suite of Lightweight Vim Plugins.","archived":false,"fork":false,"pushed_at":"2024-11-03T21:21:41.000Z","size":64,"stargazers_count":15,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-01T14:44:00.751Z","etag":null,"topics":["vim-plugin","vim9","vim9-plugin","vim9-script"],"latest_commit_sha":null,"homepage":"","language":"Vim Script","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/girishji.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":"2024-06-05T08:56:21.000Z","updated_at":"2025-02-04T16:27:28.000Z","dependencies_parsed_at":"2024-10-25T00:51:53.639Z","dependency_job_id":"d63161ae-c654-45b9-8cca-b1707fa6e575","html_url":"https://github.com/girishji/vimbits","commit_stats":null,"previous_names":["girishji/vimbits"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/girishji/vimbits","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/girishji%2Fvimbits","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/girishji%2Fvimbits/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/girishji%2Fvimbits/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/girishji%2Fvimbits/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/girishji","download_url":"https://codeload.github.com/girishji/vimbits/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/girishji%2Fvimbits/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":268716978,"owners_count":24295615,"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","status":"online","status_checked_at":"2025-08-04T02:00:09.867Z","response_time":79,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["vim-plugin","vim9","vim9-plugin","vim9-script"],"created_at":"2024-08-06T18:04:08.098Z","updated_at":"2026-02-09T11:33:04.393Z","avatar_url":"https://github.com/girishji.png","language":"Vim Script","readme":"# VimBits\n\nSuite of lightweight Vim plugins.\n\n1. [**HighlightOnYank**](#plugin-highlightonyank) - Confirm yank operation by temporarily highlighting the region.\n\n2. [**EasyJump**](#plugin-easyjump) - Jump to any location on screen by typing two characters.\n\n3. [**fFtT**](#plugin-fFtT) - Highlight characters reachable in one jump using `f`, `t`, `F`, and `T` commands. \n\n4. [**Vim9Cmdline**](#plugin-vim9cmdline) - Use *vim9script* in command-line seamlessley.\n\n5. **vimtips** from [zzapper](https://web.archive.org/web/20121104092340/http://zzapper.co.uk/vimtips.html) - `:h vimtips.txt`\n\n\n## Requirements\n\n- Vim 9.0 or higher\n\n## Installation\n\nInstall it via [vim-plug](https://github.com/junegunn/vim-plug).\n\n\u003cdetails\u003e\u003csummary\u003e\u003cb\u003eShow instructions\u003c/b\u003e\u003c/summary\u003e\n\u003cbr\u003e\n\nUsing vim9 script:\n\n```vim\nvim9script\nplug#begin()\nPlug 'girishji/vimbits'\nplug#end()\n```\n\nUsing legacy script:\n\n```vim\ncall plug#begin()\nPlug 'girishji/vimbits'\ncall plug#end()\n```\n\n\u003c/details\u003e\n\nInstall using Vim's built-in package manager.\n\n\u003cdetails\u003e\u003csummary\u003e\u003cb\u003eShow instructions\u003c/b\u003e\u003c/summary\u003e\n\u003cbr\u003e\n\n```bash\n$ mkdir -p $HOME/.vim/pack/downloads/opt\n$ cd $HOME/.vim/pack/downloads/opt\n$ git clone https://github.com/girishji/vimbits.git\n```\n\nAdd the following to your $HOME/.vimrc file.\n\n```vim\npackadd vimbits\n```\n\n\u003c/details\u003e\n\n## Configuration\n\nBy default, all plugins are enabled except for Vim9Cmdline. To disable a specific plugin, set its corresponding global variable to `false`. To enable a plugin, set its corresponding global variable to `true`.\n\n```\nvim9script\ng:vimbits_highlightonyank = true\ng:vimbits_easyjump = true\ng:vimbits_fFtT = true\ng:vimbits_vim9cmdline = false\n```\n\nMore configurable options pertaining to individual plugins are described below.\n\n# Plugin: HighlightOnYank\n\nEnsure the text you intended to yank is correctly selected. This feature helps avoid surprises when pasting, especially if you accidentally hit the wrong keys.\n\nThe yanked region is temporarily highlighted (using `:h hl-IncSearch`) for 300 milliseconds by default. The duration and highlight group are configurable, and there's an option to disable highlighting in visual mode.\n\nTo customize the default settings, add the following to your `.vimrc` file:\n\n```vim\nvim9script\ng:vimbits_highlightonyank = false  # Disables the default autocmd\nimport autoload 'vimbits/highlightonyank.vim' as hy\naugroup HighlightOnYank\n    autocmd!\n    autocmd TextYankPost * hy.HighlightOnYank('IncSearch', 300, true)\naugroup END\n```\n\n`HighlightOnYank()` accepts three arguments:\n\n- `hlgroup`: The highlight group for the yanked region.\n- `duration`: The duration of the highlight in milliseconds.\n- `in_visual`: Whether to highlight the region when yanked in visual mode.\n\nThis mini plugin is inspired by [this issue](https://github.com/vim/vim/issues/14848).\n\n# Plugin: EasyJump\n\nJump to any location on screen by typing two characters.\n\n## TL;DR\n\n- `s` + _\\\u003ccharacter\u003e_ + _\\\u003ctag_character\u003e_ to jump\n- `ds` + _\\\u003ccharacter\u003e_ + _\\\u003ctag_character\u003e_ to delete (similarly, `vs` for visual selection, `cs` for change, etc.)\n- `\u003cTab\u003e` and `\u003cS-Tab\u003e` (or `;` and `,`) after _\\\u003ccharacter\u003e_ to view additional tag characters\n- `2s` + _\\\u003ccharacter_1\u003e_ + _\\\u003ccharacter_2\u003e_ + _\\\u003ctag_character\u003e_ to jump\n\n## Features\n\n- Initially bound to `s`, but it can be reassigned to any desired trigger (e.g., `,`).\n- Supports essential Vim idioms such as `ds` for deletion, `cs` for change, `vs` for visual selection, and more. Here `s` is the trigger character.\n- Updates the jump list (`:jumps`) for easy back-navigation using `\u003cc-o\u003e`.\n- Optional two-character mode, for users accustomed to targeting with two characters instead of one.\n- Non-disruptive: Does not modify the buffer. Crafted in vim9 script.\n\n\n🚀 **Jump (`s`)**: Type `s` followed by a character (say `c`). Witness\nnew tag characters replacing the character `c`. Typing next\ncharacter initiates the jump. For instance, typing `e`\nnavigates the cursor to the `c` under `e`.\n\n\u003cimg src='https://gist.githubusercontent.com/girishji/40e35cd669626212a9691140de4bd6e7/raw/6041405e45072a7fbc4e352cbd461e450a7af90e/easyjump-img1.jpeg' width='700'\u003e\n\n🚀 **Jump back**: Type `\u003cc-o\u003e` (control-O) to jump back. Type `\u003ctab\u003e` or `\u003cc-i\u003e` to jump forward.\n\n🚀 **Visual Select (`vs`)**: For visually selecting a block of text from the\ncursor position up to an instance of `c`, enter `vsc`, then the highlighted\ncharacter (e.g., `e`).\n\n\u003cimg src='https://gist.githubusercontent.com/girishji/40e35cd669626212a9691140de4bd6e7/raw/6041405e45072a7fbc4e352cbd461e450a7af90e/easyjump-img2.jpeg' width='700'\u003e\n\nLikewise, use `ds` for deletion or `cs` for text alteration.\n\nPress `\u003cesc\u003e` to cancel the ongoing jump.\n\nPictures above are based on `:colorscheme quiet`.\n\n🔎 **What if the intended jump location is not showing a tag letter?**\n\nThis scenario occurs when there aren't enough unique letters available for\ntagging. Simply press `\u003cTab\u003e` (or `;`), and new tag labels will fill the\nremaining spots. To cycle backwards, press `\u003cS-Tab\u003e` (or `,`).\n\n🚀 **Two-Character Mode (New)**: Activated with `2s` or simply `s` if `g:easyjump_two_chars` is configured as `true`.\n\n- Use `2s` + _\\\u003ccharacter\u003e_ + _\\\u003ctag_character\u003e_ to leap to your destination (when a tag character marks the spot).\n- If no tag label is present, type the adjacent character as well, forming `2s` + _\\\u003ccharacter_1\u003e_ + _\\\u003ccharacter_2\u003e_ + _\\\u003ctag_character\u003e_ to execute the jump.\n\n\u003e [!TIP]\n\u003e A lazy way to navigate is by leveraging the space character as a guide. Experiment with typing `s` followed by `\u003cspace\u003e`. The algorithm strives to allocate one label per line. Once you're near your desired location within a line, you can [effectively employ](https://github.com/girishji/fFtT.vim) Vim's built-in `f/F, t/T` commands to reach it precisely. This is an alternative to using relative line numbers to jump.\n\n## Trigger Key\n\nBy default, `s` serves as the trigger key. To unmap `s` and restore it to the default (:h s),\ninclude the following line in your .vimrc file:\n\n```\ng:easyjump_default_keymap = false\n```\n\nTo assign `,` as the trigger for jumping, add the following lines to your `.vimrc`\nfile. You can choose any other key beside `,`.\n\n```\nnmap , \u003cPlug\u003eEasyjumpJump;\nomap , \u003cPlug\u003eEasyjumpJump;\nvmap , \u003cPlug\u003eEasyjumpJump;\n```\n\n## Case Sensitivity\n\nOptions include 'case' (case sensitive), 'icase' (ignore case), or 'smart'\n(smart case). Add the following line to your .vimrc:\n\n```\ng:easyjump_case = 'smart' # Can be 'case', 'icase', or 'smart' (default).\n```\n\n## Highlight Group\n\nThe tag letters displayed alongside destination locations utilize the\nhighlighted group `EasyJump`. By default, this group is linked to `IncSearch`. Modify its\nappearance using the `:highlight` command to change colors.\n\n## Tag Letters\n\nJump locations prioritize placement based on distance from cursor and\npreference for having at least one placement per line.\nLetters are picked in the following sequence. Modify the sequence (say, for\nDvorak) as needed. Set the following global variable:\n\n```\ng:easyjump_letters = 'asdfgwercvhjkluiopynmbtqxzASDFGWERCVHJKLUIOPYNMBTQXZ0123456789'\n```\n\n# Plugin: fFtT\n\nCharacters that are reachable with a single jump are highlighted, while others are dimmed. This enhancement enhances the accuracy of navigation using `f`, `F`, `t`, and `T` commands. Moreover, you can prefix the command with a numerical `[count]` (e.g., `3f`), which will exclusively highlight the `[count]`'th occurrence (third in this instance) of a character to the right of the cursor, while dimming the others.\n\nThis plugin does not alter Vim operators or commands. It solely focuses on highlighting relevant characters without making any changes to the default key mappings. The code consists of less than 100 lines, with explanatory comments.\n\n![](https://gist.githubusercontent.com/girishji/40e35cd669626212a9691140de4bd6e7/raw/6041405e45072a7fbc4e352cbd461e450a7af90e/fFtT-img.jpeg)\n\nThe appearance of characters that are unreachable within one jump is determined by the highlight group `FfTtSubtle`, which is linked to the `Comment` group by default.\n\n# Plugin: Vim9Cmdline\n\n*vim9script* offers significant improvements over the legacy script. Although there isn't a direct way to switch the command line to parse *vim9script*, you can execute *vim9script* commands by prepending each command with `vim9`. This plugin automates that process for you.\n\n\u003cimg src='https://gist.githubusercontent.com/girishji/40e35cd669626212a9691140de4bd6e7/raw/74e521e25364bdc01a94ce8668e8d8ef92308a59/vim9cmdline.jpeg' width='700'\u003e\n\nSome things to keep in mind:\n\n- Remember that execution occurs in the global context, not the script-local context. This means you need to declare variables with the `g:` prefix, like `g:foo = 'bar'`.\n\n- Common commands, such as visual range (`'\u003c,'\u003e`), other types of ranges, shell commands (`!`), substitution (`s//`), and global (`g//`), work as expected even when `vim9` is prepended.\n\n- Ranges to Ex commands should be prefixed with a colon. For example, `:vim9 :%s/foo/bar` (notice the `:` before `%s`).\n  From `:h [range]`:\n\n  \u003e In Vim9 script a range needs to be prefixed with a colon to avoid ambiguity\n  \u003e with continuation lines.\n\n- Related to the above, if your keymap's right-hand side (rhs) starts with a range, it may throw an error. To avoid this, use `:h \u003cCmd\u003e` or ensure the {rhs} of your keymap begins with `silent` or `:`. For example, `nnoremap your_key :% !your_cmd\u003ccr\u003e` throws an error, while `nnoremap your_key \u003ccmd\u003e% !your_cmd\u003ccr\u003e`, `nnoremap your_key :silent % !your_cmd\u003ccr\u003e` and `nnoremap your_key ::% !your_cmd\u003ccr\u003e` are OK.\n\n- Colorschemes may not load if they are written in legacy script. `:vim9 colorscheme foo` will not work unless `foo` is written in vim9script.\n\n- If you have defined a custom command with a completion function (`command -complete=custom,Foo() ...`), be aware that this function may not work as expected if it is designed to complete the n-th word. This is because there are now n+1 words, including the word `vim9`. You many need to adapt this function.\n\n- If you work with multi-byte UTF-8 characters, you'll appreciate the *vim9* command line. When slicing a UTF-8 string using the `[from : to]` operator, *vim9* is more predictable because it uses character-based addressing, unlike the byte-based addressing of the legacy script.\n\n- Legacy mode of addressing autoloaded functions and variables still work, even without legacy keywords like `call` and `let`. For instance, both `:vim9 g:foo#bar#baz()` and `:vim9 call g:foo#bar#baz()` work.\n\nYou can keep the command line in *vim9script* mode by default and switch back to the legacy script at any time using the `:ToggleVim9Cmdline` command.\n\n## Other Plugins to Enhance Your Workflow\n\n1. [**vimcomplete**](https://github.com/girishji/vimcomplete) - enhances autocompletion in Vim.\n\n2. [**devdocs.vim**](https://github.com/girishji/devdocs.vim) - browse documentation from [devdocs.io](https://devdocs.io).\n\n3. [**scope.vim**](https://github.com/girishji/scope.vim) - fuzzy find anything.\n\n4. [**VimSuggest**](https://github.com/girishji/vimsuggest) - autocompletion for Vim's command-line.\n","funding_links":[],"categories":["Vim Script"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgirishji%2Fvimbits","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgirishji%2Fvimbits","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgirishji%2Fvimbits/lists"}