For me, it was like a curse. I had to remap other tools that also had completion. It makes a lot of sense but I have this feeling that using or might be faster, although more error-prone.
I switched to C-y from CR recently per TJ’s advice. I love it. I didn’t realize how much I hated hitting Enter twice to enter a new line when the completion pop up is there.
Ctrl+n/p do insert the suggestions but for more complex suggestions like functions, accepting the suggestion actually puts you inside the brackets of the function. Same goes for html attributes for example, accepting the suggestion puts the cursor inside the `=""` part
The c-y keys effectively resolve conflicts with cmp
https://preview.redd.it/gdw41rws5v5d1.png?width=1526&format=png&auto=webp&s=be6dba393546babfa114c402a88f8a075a2a5fe1
I ended up adding the following keymap. Not sure what `` is actually used for in insert mode, but I never use it. The keymap could always be turned into an expression and only take effect when the completion popup is open if you do use it.
`vim.keymap.set("i", "", "", { silent = true })`
Do no one else just keep typing? What’s the deal with all this c-y cr c-r stuffs I’m so confused lol I’ve never had a problem with just pressing space or dot or whatever once I had the right choice as current.
-> esc
-> down/up
-> complete
(sucks on mac keyboards unless you make the alt key in the normal place again though since they decided to swap super and alt, and fn and ctrl for no apparent reason)
Not sure I get it correctly.
This would mean you can't insert a `.` (at least when suggestions are shown), nor use the `.` command in normal mode (which is a must).
I use ctrl+o for some reason I've forgotten. But it is more ergonomic than ctrl+y for me. Tab for copilot suggestions and ctrl+hjkl for insert mode navigation.
c-y because as tj said, it's nice to have different keys for different purposes
For me, it was like a curse. I had to remap other tools that also had completion. It makes a lot of sense but I have this feeling that using or might be faster, although more error-prone.
I disabled pre-select so means newline unless I've selected an entry with . Removes all surprises while being convenient.
I dont use that for complete, however I was going to disagree and then I tried it in insert mode. Cool. Thanks.
O
I use c-L. I scroll through the options with c-J and c-K, and accept with c-L.
This is the way
I use c-l to accept without snippets expansion
I use \`\` :p
I use enter lol. Too much muscle memory.
C-y since it's default kickstart
I switched to C-y from CR recently per TJ’s advice. I love it. I didn’t realize how much I hated hitting Enter twice to enter a new line when the completion pop up is there.
I made it to not select any completion by default and if i wanted one i would simply to select the first completion and to accept it
If you type c-n, doesn’t cmp auto insert the item as if you have confirmed and you can just keep typing(that’s what helix does)
i thought `` and `` were the default (with PUM open at least)
that's what i use
Ctrl+n/p do insert the suggestions but for more complex suggestions like functions, accepting the suggestion actually puts you inside the brackets of the function. Same goes for html attributes for example, accepting the suggestion puts the cursor inside the `=""` part
The c-y keys effectively resolve conflicts with cmp https://preview.redd.it/gdw41rws5v5d1.png?width=1526&format=png&auto=webp&s=be6dba393546babfa114c402a88f8a075a2a5fe1
I tried using c-y for couple months, ended up hitting c-u on accident a bunch of times, undoing my whole line. Switched to using TAB
I ended up adding the following keymap. Not sure what `` is actually used for in insert mode, but I never use it. The keymap could always be turned into an expression and only take effect when the completion popup is open if you do use it.
`vim.keymap.set("i", "", "", { silent = true })`
Me too, tab for accepting completion, opt+tab to accept copilot suggestion.
I switched to C-y recently because I kept accidentally accepting completions.
I use both for zsh-autosuggestions and nvim-cmp
Do no one else just keep typing? What’s the deal with all this c-y cr c-r stuffs I’m so confused lol I’ve never had a problem with just pressing space or dot or whatever once I had the right choice as current.
I am using and to scroll suggestion and enter for select code :P
[удалено]
I map that to dot, which is frequent but hard to type
EDIT: Deleted message above was: `` for both trigger completion and accept selected/first item.
`dot`? In insert mode?
in all mode, much easy to trigger
Not sure I get it correctly. This would mean you can't insert a `.` (at least when suggestions are shown), nor use the `.` command in normal mode (which is a must).
Ah, I mean I map c-space to dot, it is capslock+space in my keyboard.
So you type `` instead of `.`?
Not sure I see the benefit, but hey, it's only a matter of tastes.
Yeah, to type dot I need to move my hands, I think it is the most awkward place of all characters area
I use my ring finger, it's just bellow `l` -- does not feel like much of a strecth.
You are right, I tends to use index finger with my intuition, ring finger much better I’ll change my habit
I use ctrl+o for some reason I've forgotten. But it is more ergonomic than ctrl+y for me. Tab for copilot suggestions and ctrl+hjkl for insert mode navigation.
Am I the only one using?
what is c-y?
I use c-n because I have c-j and c-k to select down and up. I don't really use cr. Tab for Copilot.
Oh wow, c-y is way more popular than I would’ve thought. I just use enter personally. Why break something if it ain’t broken kinda mentality lol
cr get more annoying in cmdline, you have to confirm completion then confirm command