Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[Console] Fix the usage of the zsh completion through the fpath discovery#50110

Merged
fabpot merged 1 commit into
symfony:6.2from
stof:fix_zsh_global_completion
Apr 22, 2023
Merged

[Console] Fix the usage of the zsh completion through the fpath discovery#50110
fabpot merged 1 commit into
symfony:6.2from
stof:fix_zsh_global_completion

Conversation

@stof
Copy link
Copy Markdown
Member

@stof stof commented Apr 21, 2023

Q A
Branch? 6.2
Bug fix? yes
New feature? no
Deprecations? no
Tickets n/a
License MIT
Doc PR n/a

Zsh completion files registered through the fpath discovery mecanism have 2 requirements:

  • the file name must have a _ prefix
  • the file must start with a #compdef comment describing the registration for that file.

The file can then either execute the completion logic directly or call compdef to register a function for completion. Keeping the second approach allows to use the same generated script for the global use case than for a sourced configuration script.

Zsh completion files registered through the fpath discovery mecanism
have 2 requirements:

- the file name must have a `_` prefix
- the file must start with a `#compdef` comment describing the
  registration for that file.

The file can then either execute the completion logic directly or call
`compdef` to register a function for completion. Keeping the second
approach allows to use the same generated script for the global use case
than for a sourced configuration script.
@fabpot
Copy link
Copy Markdown
Member

fabpot commented Apr 22, 2023

Thank you @stof.

@fabpot fabpot merged commit 180eb01 into symfony:6.2 Apr 22, 2023
@fabpot fabpot mentioned this pull request Apr 28, 2023
@stof stof deleted the fix_zsh_global_completion branch May 11, 2023 13:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants