No description
Find a file
hrsh7th 91ff86cd9c
Merge pull request #53 from amarakon/main
Remove the leading slash from the directory label
2022-10-03 17:04:43 +09:00
after/plugin Initial commit 2021-08-03 23:51:11 +09:00
lua/cmp_path Change visual_slash to label_trailing_slash 2022-10-03 02:19:15 -04:00
LICENSE Create LICENSE 2021-11-10 20:30:12 +09:00
README.md README: Change false to true 2022-10-03 03:49:32 -04:00

cmp-path

nvim-cmp source for filesystem paths.

Setup

require'cmp'.setup {
  sources = {
    { name = 'path' }
  }
}

Configuration

The below source configuration options are available. To set any of these options, do:

cmp.setup({
  sources = {
    {
      name = 'path',
      option = {
        -- Options go into this table
      },
    },
  },
})

trailing_slash (type: boolean)

Default: false

Specify if completed directory names should include a trailing slash. Enabling this option makes this source behave like Vim's built-in path completion.

label_trailing_slash (type: boolean)

Default: true

Specify if directory names in the completion menu should include a trailing slash.

get_cwd (type: function)

Default: returns the current working directory of the current buffer

Specifies the base directory for relative paths.