supermaven-inc / supermaven-nvim

The official Neovim plugin for Supermaven
https://supermaven.com/
MIT License
279 stars 16 forks source link

feature update: use cmp built in types and cursor; add pro tip to readme #30

Open kaiiserni opened 1 month ago

kaiiserni commented 1 month ago

Description

I previously made a PR (accepted) which introduced cmp source integration and a couple of convenience methods. #28

This pull request contains a minor update to make better use of built in cmp types and multi line markers, cursor, etc. I had added my own marker previously, so it doesn't change much. But I feel it is cleaner this way.

I also tried to simulate the built in continuous inline completions with cmp and came up with a solution which has been working nicely for me for the last couple of days now, so I thought I could share this as a "pro tip" in the README, although this may perhaps be better suited for a wiki in the future.

The new README suggestion is demonstrated in this video:

https://github.com/supermaven-inc/supermaven-nvim/assets/87830/9871857a-56d3-44f9-abfc-b727f01d3565

Please let me know if there is anything else I need to address before accepting this pull request.

Type of change

How Has This Been Tested?

I have tested it thoroughly on Lua and TypeScript projects, and it works as expected, providing both single and multi-line suggestions.

Configuration:

Checklist

kaiiserni commented 1 month ago

@victorw-xyz fwiw, I also took the liberty of listing Supermaven in the official list of cmp sources: https://github.com/hrsh7th/nvim-cmp/wiki/List-of-sources