Skip to content

Releases: saghen/blink.cmp

v1.8.0

14 Nov 19:07
v1.8.0
b19413d

Choose a tag to compare

Highlights

  • Frizbee updated to 0.6.0 for ~2x performance boost
  • Mostly eliminated overhead while running macros
  • Removed stat calls and reduced memory usage in path source

Features

  • allow string return in keymap (#2144) (7fc7947)
  • cmdline: enable buffer source for grep commands (1596716), closes #2251
  • fuzzy: allow setting sort list as a function (#2189) (138314a)

Bug Fixes

  • blink.cmp.KeymapCommand type annotations (#2180) (a999ddc)
  • clamp the start and end lines of the range (#2177) (89c196f), closes #2170
  • cmdline: handle :=expr for proper Lua expression completion (2fcf66a)
  • cmdline: skip filename modifiers detection when using help command (cb87357), closes #2211
  • cmdline: skip handling command separator during path completion (cc8c9b7), closes #2192
  • correct usage of 'e.g.' and 'i.e.' in documentation (1e96a5b)
  • disable in macros (afc4f4d), closes #2161
  • don't modify global &iskeyword (#2223) (8743384)
  • ellipsis double width replacement not applied (#2225) (312097b)
  • injected per-filetype providers not inheriting default providers (40380e7)
  • luasnip: only pass fallback_match if different from line_to_cursor (a60d8c0)
  • luasnip: use actual cursor pos for snippet match (#2206) (de2f709)
  • menu: add missing loading item properties (ab1b366), closes #2
  • nix: fix Cargo sandbox builds on Darwin via Fenix update (#2226) (d93e01a)
  • snippet: handle $VAR and ${VAR} variable forms correctly (a4ab037), closes #2212
  • snippets: ensure proper espcaping of special chars (#2239) (230ccf8), closes #2072 #2028
  • snippets: provide textEdit field for builtin snippet (#2233) (2408f14), closes #2159
  • stick to vsnip API in vimscript (#2197) (5eb4e7f)

Performance Improvements

  • path: drop unused stat calls (2b44b9c), closes #2196
  • path: improve async dir scan with chunked callbacks (#2204) (5037cfa), closes #2196
  • path: limit max entries per directory to 5000 (5b4055e), closes #2196

New Contributors

Full Changelog: v1.7.0...v1.8.0

v1.7.0

15 Sep 16:34
v1.7.0
327fff9

Choose a tag to compare

Highlights

  • Configurable delay before showing completion menu (completion.menu.auto_show_delay_ms)
  • Added :BlinkCmp build command for building fuzzy matching library from source, primarily for vim.pack users building from soruce
  • Dropped LMDB in favor of pure Rust implementation for frecency DB, resolving neovim crashing on accepting completions
    • Moved from ~/.local/share/nvim/blink/cmp/fuzzy.db to ~/.local/state/nvim/blink/cmp/frecency.dat
  • Added support for vsnip via snippets.preset = 'vsnip'
  • Fixed stutter on InsertEnter when using snippets with TM_SELECTED_TEXT (such as with friendly-snippets in latex)
  • Misc cmdline fixes/performance improvements

Features

  • completion.menu.auto_show_delay_ms option (debe907), closes #619
  • scroll_signature_up/down keymap commands (#2057) (b7e2404)
  • add :BlinkCmp build and :BlinkCmp build-log commands (4c6a29e)
  • add show_and_insert_or_accept_single keymap, set as <Tab> in cmdline (#2037) (a93cdb8), closes #2032
  • add snippet_indicator option #2034 (#2038) (5e1c0e8)
  • add snippets.preset = 'vsnip' (#2110) (221c3d8)
  • append-only frecency database, drop LMDB (#2136) (f1c3905)
  • brackets: add css pseudo-class exceptions (#2054) (e3f28f1), closes #2052
  • cmdline: handle ex special characters and filename modifiers (#2074) (f6ca10f), closes #2068
  • fuzzy: make frecency database path configurable (#2061) (b8154b4), closes #2006
  • keymap: add jump_by option to navigate by item property (6a84282), closes #1890
  • keymap: add fallback action to mapping (#2064) (d9fa997), closes #2063
  • luasnip: pass matched part of trigger to luasnip. (#2132) (6bceed7)
  • remove item.documentation.render (aeba0f0)
  • snippets: add option sources.providers.snippets.opts.use_label_description (#2094) (34e4483)

Bug Fixes

  • :BlinkCmp build working directory (5209af5)
  • add svelte to javascript auto-brackets import exception (#2152) (5a4461b), closes #2151
  • cmdline: respect wildignore during command-line completion (dc68824), closes #2083
  • cmdline: support wildcard completion in file (7b0548e), closes #2106
  • cmdline: translate mappings for use with :map (7770a67), closes #2126
  • disable frecency writing when not enabled (fa9e5fa), closes #2031
  • fuzzy: check shared lib existence before skipping download (#2055) (b745bea), closes #2048
  • ghost_text: validate buffer before redraw to prevent errors (#2050) (16b6ba0), closes #1764
  • keymap: accept completion when only one item remains (54cc521)
  • keymap: add fallback action to mapping (c375967)
  • libc detection failing on shorter triples (6d35b78), closes #2040
  • Move runtime inputs to derivation args and add libiconv for macOS compatibility (#1993) (4834ecf)
  • presets: add missing cmdline preset to hide completion on <End> (#2030) (1a5607f)
  • prevent out of bounds scrollbar position (e465c73)
  • use table.concat instead of vim.fn.join for provider list (4e9edba)
  • window: clamp highlights to prevent overflow beyond text bounds (#2049) (d73dfcb)

Performance Improvements

  • cmdline: reduce spurious cursor and char events (#1953) (6323a6d)
  • snippets: cache lazy vars when expanding vars (33f0789), closes #2024
  • snippets: fix previous attempt at caching snippet lazy vars (ce26f9f), closes #2024

Reverts

  • Move runtime inputs to derivation args and add libiconv for macOS compatibility (#1993) (a0bcede), closes #2044

New Contributors

Full Changelog: v1.6.0...v1.7.0

v1.6.0

24 Jul 16:07
v1.6.0
bae4bae

Choose a tag to compare

Highlights

  • Fuzzy matching:
    • Always prefer continuous matches over fuzzy matches (i.e. foo on foobar beats f_o_o_bar) (Change made in v1.5.0 but forgot to mention it)
    • OFFSET_PREFIX_BONUS for matching second character, if the first character is not a letter and not matched (i.e. h on _hello)
    • Lua implementation no longer ignores score_offset
  • Fixed regression where text after the cursor was not being replaced

Features

  • add .get_context() function to API (6f3ed55)
  • add count option to select_next and select_prev (796a00e), closes #569
  • add OFFSET_PREFIX_BONUS to lua matcher (2faf063)
  • add terminal_command to the completion context (#2001) (b163deb)
  • bump frizbee to 0.5.0 with offset prefix bonus (b6ea46e)
  • lazily get TM_SELECTED_TEXT for snippets (04f9f22), closes #1998
  • snippet: support variables in placeholders (277203b), closes #950
  • update menu position on selection with dynamic direction priority (d89b7e4), closes #2000

Bug Fixes

  • apply score_offset and snippet.score_offset with lua matcher (6c1d41e)
  • applying score_offset on nil match (3545f6d)
  • cmdline: avoid doubling variable scope prefixes in expression (60f446a), closes #1994
  • cmdline: improve prefix handling to avoid duplication in expression (af22c52), closes #2005
  • eager error in snippets (adaff22)
  • log errors from downloader and fallback to lua (b812f16), closes #1999
  • revert #1985 "use edit range start for compensation instead of old cursor" (4663e23), closes #2013

Full Changelog: v1.5.1...v1.6.0

v1.5.1

15 Jul 19:46
v1.5.1
586ee87

Choose a tag to compare

Bug Fixes

  • add backward compatibility for offset encoding conversion (02ee0a1), closes #1988

Full Changelog: v1.5.0...v1.5.1

v1.5.0

13 Jul 16:08
v1.5.0
3536ce4

Choose a tag to compare

Highlights

  • ~1.5-3x global speed-up due to dropping items on BlinkCmp* autocmds
    • You may use require('blink.cmp').get_items() instead
  • Buffer source rewrite (#1964)
    • Per-buffer caching for 2-100x speed-up, depending on the number, uniqueness and size of the buffers
    • Added total size cap of 500k chars (max_total_buffer_size) with configurable rentention_order
  • Enable cmdline source in command-line-window (q:)

Thank you @soifou for practically writing the whole release!

Features

  • cache buffer items by changedtick (5e8165b)
  • add clangd hack, adding .lsp_score to completion items (ca9019c), closes #1778
  • add blink-cmp-wezterm source (#1951) (a5081e8)
  • add blink-cmp-words to community sources (#1938) (f4ecb69)
  • cmdline: autoshow for cmdwin (36de2a7)
  • cmdline: enable in command-line-window and vim filetype (78b42f6), closes #1835 #1447
  • cmdline: support getcompletiontype for cmdwin (ec03764)
  • drop BlinkCmpSourceCompletions (dc62667)
  • prefer continuous matches (#1888) (2096cf1)

Bug Fixes

  • add racket to blocked filetypes for auto brackets (f31a46e), closes #1965
  • cmdline: :s/:g/:v don't trigger auto completion (#1956) (19a2ba4)
  • cmdline: avoids unintended prefix duplication of user-defined command (36ea052)
  • cmdline: do not mutate label description for boolean option (04b8325)
  • cmdline: improve Vim expression detection and handle custom completions (fe7c974)
  • cmdline: pick last pasted char for completion, not just the first (#1952) (e84b7d9), closes #1940
  • cmdline: prepend prefix for expressions (c880c77), closes #1939
  • cmdline: prevent error when unique prefix for buffer is missing (644fef3), closes #1927
  • cmdline: prevent hangs from shellcmd completion on win32/wsl (#1933) (1cc44a3), closes #1926 #1029
  • ghost_text: prevent out-of-bounds on multiline edits (#1967) (f66e22e), closes #1197 #1739
  • handle completion type for even more edge cases (78a6275)
  • keyword suffix matching and drop leading dash in lua impl (6c4302b), closes #1792
  • lsp: filter out text completion items only for lua_ls (#1979) (2f2ebc5), closes #1838
  • luasnip: avoid false positives for in-snippet detection (#1969) (47820df), closes #1805 #1966
  • minor signature improvements (#1971) (6d6b009)
  • show_signature now ignores trigger.enabled if called directly (#1946) (83e6a29)
  • signature show failing due to opts not defined (#1949) (dad68b3)
  • use cmdline config for cmdwin, add wrapper for completion type (a4e2be4)
  • use edit range start for compensation instead of old cursor (#1985) (d2ca33f), closes #1736 #1978
  • use lsp offset encoding when compensating text edit range (17e30f3)
  • winborder: handle custom border chars (#1984) (a946054)

Performance Improvements

New Contributors

Full Changelog: v1.4.1...v1.5.0

v1.4.1

17 Jun 18:11
v1.4.1
9bcb14b

Choose a tag to compare

Features

Bug Fixes

  • ! prefix completion (#1912) (9c5d823)
  • cmdline: correctly handle filetype completions (c9de9dd)
  • cmdline: skip path completion handler when using vim expressions (9da629b), closes #1922

New Contributors

Full Changelog: v1.4.0...v1.4.1

v1.4.0

16 Jun 14:53
v1.4.0
729d023

Choose a tag to compare

Highlights

  • Improved edit range guessing (#923)
    • Clojure and other LSPs which don't send edit ranges should no longer insert the prefix
  • Sort in rust when no lua sorts provided (in fuzzy.sorts table)
    • Improves performance by ~40% on long lists (i.e. from tailwind)
  • Resolved neovim crash on large completions, i.e. from copilot (thank you @otakenz!)
  • Major cmdline work by @soifou
    • Paths no longer contain their prefix (such as in :e) and fuzzy match correctly
      • Escaped spaces in paths now work as expcted
    • Shows shortest unique prefix for :buffer items
    • Buffer completion on :s/foo/bar/ and :g
      • Due to an upstream issue, requires providers.buffer.opts.enable_in_ex_commands = true)
      • Note that this option disables inccommand

Features

  • add ! as cmdline trigger character (59a58b5)
  • add completion.trigger.show_on_insert option (#1796) (03c5fea)
  • buffer: add configurable sync/async buffer size thresholds (#1795) (d324508), closes #1789
  • cmdline: add buffer completion for :s and :g commands (#1734) (75c9117), closes #1625
  • completion.trigger: add show_on_backspace_* options (#1813) (0289534)
  • don't disable signature help when pumvisible (396f19a)
  • frecency: use blake3 hash as db key for accesses (#1908) (9c007ae)
  • handle multiple filetypes in per_filetype table (#1798) (becda04)
  • improved edit range guess logic (5cf9a78), closes #923
  • make max_typos optionally a number (980b09c)
  • sort in rust when no lua sorts provided (#1830) (faee548), closes #1752
  • space instead of autobrackets for lean (#1825) (cd83fee)
  • update repro.lua with mason (3e7b05e)
  • window: support function for direction_priority in menu and signature (#1873) (d59d55d), closes #1801

Bug Fixes

  • add fennel and jannet to blocked auto bracket filetypes (#1804) (a434b7b)
  • add ps1 (powershell) to blocked auto bracket filetypes (#1816) (992644b)
  • add dot-repeat hack to terminal mode (#1788) (9873411)
  • add missing comma in configuration examples (#1867) (7370740)
  • avoid overlapping signature window with popupmenu (0fc23d2)
  • buffer: deduplicate words globally (#1790) (c2bac7f), closes #1789
  • check for trigger character after semantic token auto brackets (755bc7e)
  • cmdline: use current argument for 'file' completion in input() prompts (#1821) (92029d3), closes #1817
  • completion: reset selected_item_idx on hide to prevent stale selection (#1860) (8cab663), closes #1856
  • default providers used when filetype specific sources are empty (3e4a237)
  • disable completion.trigger.show_on_insert, add to reference (084439e)
  • disabling keymaps in cmdline/term mode not working (94000bd), closes #1855
  • handle delay on :ts xx No tags file error (#1814) (fd6e9c6)
  • keymap: disable preset keymaps with false (#1859) (0d9a7e4), closes #1855
  • panic on no matched indices (bf612a5), closes #1902
  • perform keyword range checks on bytes instead of chars (30f0a7b), closes #1834
  • put output values of guess_keyword_range into a table (#1833) (f03e488)
  • rust sorting provider order (#1880) (8d0b89b), closes #1876 #1846
  • screenpos in floating window due to incorrect winid (#1853) (fe44a7d)
  • skip useless redraws when not running in Neovide (#1903) (feb34a9)
  • snippet edit range with lua implementation (29c8d72), closes #1340
  • use vim.tbl_isempty to check for empty providers table (7c76cf5)
  • window: ensure completion buffer is modifiable before rendering (#1891) (024727a), closes #1889
  • window: hide all blink windows when another completion menu is triggered (#1852) (e7dcfe4), closes #1806

Performance Improvements

  • only check for tailwind colors when doc length = 7 (02d5e15), closes #1752

New Contributors

Read more

v1.3.1

15 May 01:43
v1.3.1
022521a

Choose a tag to compare

Bug Fixes

  • flake: aarch64 build on nix fails because of jemalloc (#1759) (ef037d0)
  • only set error notifications to err in nvim_echo (#1763) (12a530f)

New Contributors

Full Changelog: v1.3.0...v1.3.1

v1.3.0

13 May 18:54
v1.3.0
54cbaac

Choose a tag to compare

Features

  • add signature.trigger.show_on_accept/show_on_accept_on_trigger_character (6770a4a), closes #1722
  • add extmarks at the start of terminal commands as a utility for creating shell completions (#1747) (584e280)
  • add message on prebuilt binary download completion (0a36e07)

Bug Fixes

  • get up to date cursor in luasnip execute (3077615), closes #1740
  • guard against nil triples (cdbe943), closes #1730
  • lua implementation not respecting match_suffix option (091d09e)
  • nvim 0.10 compatibility for nvim_echo (#1760) (834e419)
  • only use largest range when item is a snippet (59507fd)
  • treat dash as keyword in lua implementation (45fcabc), closes #1756
  • use string.buffer for frecency access (6dc82a0), closes #1627

New Contributors

Full Changelog: v1.2.0...v1.3.0

v1.2.0

02 May 17:20
v1.2.0
4f38ce9

Choose a tag to compare

Highlights

  • Fuzzy matcher performance and correctness improvements (v0.3.0..v0.4.2)
  • sources.per_filetype.*.inherit_defaults for inheriting from the default sources (docs)
  • nvim_echo for fancy notifications and error messages (Thanks @OXY2DEV!)
  • Many bug fixes

Features

  • ignore_root_slash option for path source (#1678) (5295e6a)
  • add completion.menu.draw.cursorline_priority (5b11128)
  • add sources.per_filetype.*.inherit_defaults to inherit from default (4a1a685), closes #1669
  • add bold style for border (#1687) (7856f05)
  • begin typing async tasks (a745202)
  • extend tailwind color hack to cssls (#1594) (54c5c9c)
  • ignore keyword length on trigger character (#1699) (f233029)
  • option to run select_next/prev when only ghost text is visible (a5be099), closes #1572
  • prioritize lowercase over uppercase in label sort (bdb1497), closes #1642
  • remove 1024 char limit on fuzzy (7281aed), closes #1473
  • revert show ~ indicator for items which expand as snippets (39622d1)
  • set glibc to 2.17 for linux builds (efa0b4d), closes #1482
  • show ~ indicator for items which expand as snippets (7bf9d6c), closes #1660
  • simplify repro.lua (ca7e138)
  • temporarily disable prefetching (aace22d), closes #1633
  • use blink-cmp-dot-repeat filetype for dot repeat buffer (651a3d4), closes #1623
  • use nvim_echo for emitting errors and notifs (#1523) (695a7ed), closes #973 #1628
  • use buffer events suppression hach for cmdline events (596a386), closes #1649
  • use built-in markdown renderer for documentation (30f0749), closes #1579
  • use current buffer only in search mode (dcd783e), closes #1592
  • use linebreak on documentation window (53b2b05), closes #1579

Bug Fixes

  • avoid undefined highlight group 'CmpGhostText' (#1617) (76f11c4)
  • bump frizbee to 0.4.1 (c3a5421), closes #1642 #1147
  • close dir handle on read failure in path source (7dc5a6b)
  • cmdline: handle error if getcompletion returns an error (#1700) (4e119c5)
  • default sources not being used (f1efa3b)
  • disable auto brackets by default for cpp filetype (#1595) (0528949)
  • disable auto brackets in typescript imports (72cdff5), closes #1609
  • disable Neovide drawing when setting up dot repeat (#1582) (d5943ac)
  • ghost text failing to clear (84b7b9f), closes #1581
  • ghost_text preview error on completion cancellation at buffer end (#1676) (11ed30a)
  • inconsistent menu cycling behavior (efde0c2), closes #1637
  • luasnip: guard against missing callbacks (fa7ad0a), closes #1643
  • multi-line snippet indentation when no placeholders (9ac195c), closes #1635
  • protect against non-empty empty textEdit (#1601) (6cd64bd)
  • remove unsupported params field from draw highlight type (7e313f0)
  • remove unused keys from mode specific keymaps (405bd23)
  • schedule nvim_echo (#1683) (f2e4f6a)
  • sending exact and score to lsp (e08ae37), closes #1667
  • serialization issue with draw function (#1719) (d361815)
  • snippets: strings like %20 in the register resulting in repeated errors (#1693) (4040d83)
  • unhandled terminal mode in set_cursor implementation (#1672) (07a09ac)
  • unify and correct source list type (#1622) (e16586c)

Performance Improvements

  • mark help tags as complete backwards (ea29ab1), closes #1538

New Contributors

Read more