Skip to content

Latest commit

 

History

History
51 lines (37 loc) · 1.39 KB

README.md

File metadata and controls

51 lines (37 loc) · 1.39 KB

vim-github-codeowners

A vim plugin for interacting with GitHub's CODEOWNERS file.

Requirements

Installation

Install vim-github-codeowners as any other plugin through the use of vim-plug, Vundle, pathogen or your favourite vim plugin manager.

Plug 'mrded/vim-github-codeowners', {'do': 'npm install'}

Commands

  • CodeownersWho - shows a codeowner of active file.
  • CodeownersReset - resets cache.

Airline Configuration

vim airline codeowners screenshot

To show a codeowner in an Airline section:

function! AirlineInit()
  let g:airline_section_z = airline#section#create(['codeowners'])
endfunction

autocmd User AirlineAfterInit call AirlineInit()

Lightline Configuration

To show a codeowner in a Lightline section:

let g:lightline = {
      \   'active': {
      \     'right': [['codeowners']]
      \   },
      \   'component_function': {
      \     'codeowners': 'codeowners#whoBufname'
      \   },
      \ }