Skip to content

fbuchlak/cmp-symfony-router

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cmp-symfony-router

symfony routes source for nvim-cmp

Dependencies

Installation

lazy.nvim

{
    "fbuchlak/cmp-symfony-router",
    dependencies = { "nvim-lua/plenary.nvim" }
},

Setup

Add symfony_router as cmp source

require("cmp").setup {
    sources = {
        {
            name = "symfony_router",
            -- these options are default, you don't need to include them in setup
            option = {
                console_command = { "php", "bin/console" }, -- see Configuration section
                cwd = nil, -- string|nil Defaults to vim.loop.cwd()
                cwd_files = { "composer.json", "bin/console" }, -- all these files must exist in cwd to trigger completion
                filetypes = { "php", "twig" },
            }
        },
    },
}

Configuration

console_command

Defines symfony console executable

-- examples
{ "bin/console" } -- call console executable directly
{ "symfony", "console" } -- using symfony cli
{ "docker", "exec", "CONTAINER_NAME", "php", "bin/console" } -- docker
{ "docker", "compose", "exec", "SERVICE_NAME", "php", "bin/console" } -- docker compose

Releases

No releases published

Packages

No packages published

Languages