{"id":13479843,"url":"https://github.com/justinmk/vim-sneak","last_synced_at":"2025-05-13T23:06:50.796Z","repository":{"id":10741356,"uuid":"12998237","full_name":"justinmk/vim-sneak","owner":"justinmk","description":"The missing motion for Vim :athletic_shoe:","archived":false,"fork":false,"pushed_at":"2025-02-03T09:02:08.000Z","size":753,"stargazers_count":3353,"open_issues_count":20,"forks_count":89,"subscribers_count":22,"default_branch":"master","last_synced_at":"2025-04-05T11:00:40.217Z","etag":null,"topics":["motion","navigation","neovim","neovim-plugin","nvim","plugin","vim","vim-plugin","viml"],"latest_commit_sha":null,"homepage":"http://www.vim.org/scripts/script.php?script_id=4809","language":"Vim Script","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"camwiegert/in-view","license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/justinmk.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":"2013-09-21T16:26:40.000Z","updated_at":"2025-04-04T20:14:56.000Z","dependencies_parsed_at":"2023-01-13T16:07:31.704Z","dependency_job_id":"a7aca0ad-4413-4b84-bc62-182b932d802f","html_url":"https://github.com/justinmk/vim-sneak","commit_stats":{"total_commits":335,"total_committers":29,"mean_commits":"11.551724137931034","dds":"0.11343283582089547","last_synced_commit":"c13d0497139b8796ff9c44ddb9bc0dc9770ad2dd"},"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justinmk%2Fvim-sneak","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justinmk%2Fvim-sneak/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justinmk%2Fvim-sneak/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justinmk%2Fvim-sneak/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/justinmk","download_url":"https://codeload.github.com/justinmk/vim-sneak/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248572102,"owners_count":21126585,"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":["motion","navigation","neovim","neovim-plugin","nvim","plugin","vim","vim-plugin","viml"],"created_at":"2024-07-31T16:02:23.818Z","updated_at":"2025-04-12T13:23:27.004Z","avatar_url":"https://github.com/justinmk.png","language":"Vim Script","funding_links":[],"categories":["Vim Script","Tools"],"sub_categories":["Text Navigation","Editing"],"readme":"sneak.vim 👟\n================\n\nJump to any location specified by two characters.\n\nSneak is a powerful, reliable, yet minimal _motion_ plugin for Vim. It works with **multiple\nlines**, **operators** (including repeat `.` and [surround]), motion-repeat\n(`;` and `,`), **[keymaps]**, **visual** mode, **[multibyte]** text, and\n**macros**.\n\nTry *label-mode* for a minimalist alternative to\n[EasyMotion](https://github.com/easymotion/vim-easymotion):\n\n```vim\nlet g:sneak#label = 1\n```\n\nUsage\n-----\n\n\u003ca href=\"http://imgur.com/Jke0mIJ\" title=\"Click to see a short demo\"\u003e\u003cimg src=\"https://raw.github.com/justinmk/vim-sneak/fluff/assets/readme_diagram.png\"\u003e\u003c/a\u003e\n\nSneak is invoked with `s` followed by exactly two characters:\n\n    s{char}{char}\n\n* Type `sab` to **move the cursor** immediately to the next instance of the text \"ab\".\n    * Additional matches, if any, are highlighted until the cursor is moved.\n* Type `;` to go to the next match (or `s` again, if `s_next` is enabled; see [`:help sneak`](doc/sneak.txt)).\n* Type `3;` to skip to the third match from the current position.\n* Type `ctrl-o` or ``` `` ``` to go back to the starting point.\n    * This is a built-in Vim motion; Sneak adds to Vim's [jumplist](http://vimdoc.sourceforge.net/htmldoc/motion.html#jumplist)\n      *only* on `s` invocation—not repeats—so you can \n      abandon a trail of `;` or `,` by a single `ctrl-o` or ``` `` ```.\n* Type `s\u003cEnter\u003e` at any time to repeat the last Sneak-search.\n* Type `S` to search backwards.\n\nSneak can be limited to a **vertical scope** by prefixing `s` with a [count].\n\n* Type `5sxy` to go immediately to the next instance of \"xy\" within 5 columns\n  of the cursor.\n\nSneak is invoked with [**operators**](http://vimdoc.sourceforge.net/htmldoc/motion.html#operator)\nvia `z` (because `s` is taken by surround.vim).\n\n* Type `3dzqt` to delete up to the *third* instance of \"qt\".\n    * Type `.` to repeat the `3dzqt` operation.\n    * Type `2.` to repeat twice.\n    * Type `d;` to delete up to the next match.\n    * Type `4d;` to delete up to the *fourth* next match.\n* Type `yszxy]` to [surround] in brackets up to `xy`.\n    * Type `.` to repeat the surround operation.\n* Type `gUz\\}` to upper-case the text from the cursor until the next instance\n  of the literal text `\\}`\n    * Type `.` to repeat the `gUz\\}` operation.\n\nInstall\n-------\n\nRequires Vim 7.3+ or [Nvim](https://neovim.io/). Label-mode requires Vim\n7.4.792+. With Nvim 0.5+ label-mode is driven by [virtual text](https://neovim.io/doc/user/api.html#nvim_buf_set_extmark())\ninstead of the legacy \"conceal\" feature.\n\n- [vim-plug](https://github.com/junegunn/vim-plug)\n  - `Plug 'justinmk/vim-sneak'`\n- [Pathogen](https://github.com/tpope/vim-pathogen)\n  - `git clone git://github.com/justinmk/vim-sneak.git ~/.vim/bundle/vim-sneak`\n- Manual installation:\n  - Copy the files to your `.vim` directory.\n\nTo repeat Sneak *operations* (like `dzab`) with dot `.`,\n[repeat.vim](https://github.com/tpope/vim-repeat) is required.\n\nFAQ\n---\n\n### Why not use `/`?\n\nFor the same reason that Vim has [motions](http://vimdoc.sourceforge.net/htmldoc/motion.html#left-right-motions)\nlike `f` and `t`: common operations should use the fewest keystrokes.\n\n* `/ab\u003ccr\u003e` requires 33% more keystrokes than `sab`\n* Sets *only* the initial position in the Vim jumplist—so you can explore a\n  trail of matches via `;`, then return to the start with a single `ctrl-o` or ``` `` ```\n* Doesn't clutter your search history\n* Input is always literal (don't need to escape special characters)\n  * Ignores accents (\"equivalence class\") when matching\n    ([#183](https://github.com/justinmk/vim-sneak/issues/183))\n* Smarter, subtler highlighting\n\n### Why not use `f`?\n\n* 50x more precise than `f` or `t`\n* Moves vertically\n* Highlights matches in the direction of your search\n\n### How dare you remap `s`?\n\nYou can specify any mapping for Sneak (see [`:help sneak`](doc/sneak.txt)).\nBy the way: `cl` is equivalent to `s`, and `cc` is equivalent to `S`.\n\n### How can I replace `f` with Sneak?\n\n```vim\nmap f \u003cPlug\u003eSneak_s\nmap F \u003cPlug\u003eSneak_S\n```\n\n### How can I replace `f` and/or `t` with *one-character* Sneak?\n\nSneak has `\u003cPlug\u003e` mappings for `f` and `t` 1-character-sneak.\nThese mappings do *not* invoke label-mode, even if you have it enabled.\n\n```vim\nmap f \u003cPlug\u003eSneak_f\nmap F \u003cPlug\u003eSneak_F\nmap t \u003cPlug\u003eSneak_t\nmap T \u003cPlug\u003eSneak_T\n```\n\nRelated\n-------\n\n* [Seek](https://github.com/goldfeld/vim-seek)\n* [EasyMotion](https://github.com/Lokaltog/vim-easymotion)\n* [smalls](https://github.com/t9md/vim-smalls)\n* [improvedft](https://github.com/chrisbra/improvedft)\n* [clever-f](https://github.com/rhysd/clever-f.vim)\n* [vim-extended-ft](https://github.com/svermeulen/vim-extended-ft)\n* [Fanf,ingTastic;](https://github.com/dahu/vim-fanfingtastic)\n* [IdeaVim-Sneak](https://plugins.jetbrains.com/plugin/15348-ideavim-sneak)\n* [leap.nvim](https://github.com/ggandor/leap.nvim)\n* [flash.nvim](https://github.com/folke/flash.nvim)\n\nLicense\n-------\n\nCopyright © Justin M. Keyes. Distributed under the MIT license.\n\n[multibyte]: http://vimdoc.sourceforge.net/htmldoc/mbyte.html#UTF-8\n[keymaps]: http://vimdoc.sourceforge.net/htmldoc/mbyte.html#mbyte-keymap\n[surround]: https://github.com/tpope/vim-surround\n[count]: http://vimdoc.sourceforge.net/htmldoc/intro.html#[count]\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjustinmk%2Fvim-sneak","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjustinmk%2Fvim-sneak","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjustinmk%2Fvim-sneak/lists"}