Skip to content

fix: user command completion on v0.12.0#296

Open
c-c-k wants to merge 3 commits intonoib3:mainfrom
c-c-k:stack/025-pr-fix-user-command-completion-on-v0.12.0
Open

fix: user command completion on v0.12.0#296
c-c-k wants to merge 3 commits intonoib3:mainfrom
c-c-k:stack/025-pr-fix-user-command-completion-on-v0.12.0

Conversation

@c-c-k
Copy link
Copy Markdown
Contributor

@c-c-k c-c-k commented Apr 3, 2026

Depends on #295 for neovim-0-12 feature flag.

Changes CommandInfos::complete's type from String to CommandComplete and adds a custom serde deserializer for CommandComplete for NVIM v0.12.0 and Nightly.

This was necessary to fix the failing create_del_user_command and user_command_with_count tests because v0.12.0 modified a few of the builtin plugins commands to define the complete field directly as a Lua function instead of as a "customlist" with a complete_arg="v:lua..." field.

I have applied the change only to v0.12.0 and Nightly but it is actually compatible with v0.10.0 and v0.11.0 as well.

In addition the I have updated the values in the CommandComplete enum to the corresponding values available in NVIM v0.10.0, v0.11.0 and v0.12.0.

Because the original CommandComplete enum already had a field named CustomList which was mapped to a function upon creation of a new command I have added the values CustomFromCompleteArg and CustomlistFromCompleteArg
which map to "custom" and "customlist".

@c-c-k c-c-k force-pushed the stack/025-pr-fix-user-command-completion-on-v0.12.0 branch from bb19716 to 7b96ca2 Compare April 4, 2026 09:26
@c-c-k c-c-k marked this pull request as ready for review April 4, 2026 09:28
@c-c-k c-c-k changed the title Stack/025: fix user command completion on v0.12.0 fix: user command completion on v0.12.0 Apr 5, 2026
@c-c-k
Copy link
Copy Markdown
Contributor Author

c-c-k commented Apr 6, 2026

Will drop the v0.10 flags, sec

@c-c-k c-c-k force-pushed the stack/025-pr-fix-user-command-completion-on-v0.12.0 branch from 7b96ca2 to 059baf6 Compare April 6, 2026 10:22
c-c-k added 3 commits April 22, 2026 18:13
* Change `CommandInfos::complete`'s type from `String` to `CommandComplete`.
* Add custom serde deserializer for `CommandComplete`.
@c-c-k c-c-k force-pushed the stack/025-pr-fix-user-command-completion-on-v0.12.0 branch from 059baf6 to 6c884f0 Compare April 22, 2026 16:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant