Skip to content

Commit d0bc004

Browse files
committed
Show how to integrate with Lightline
1 parent 8409d50 commit d0bc004

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

README.md

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ Plug 'mrded/vim-github-codeowners', {'do': 'npm install'}
2525

2626
![vim airline codeowners screenshot](https://user-images.githubusercontent.com/347098/91915409-63262700-ecb2-11ea-8502-52f820e22c75.png)
2727

28-
To show a codeowner in an [vim-airline](https://github.com/bling/vim-airline) section:
28+
To show a codeowner in an [Airline](https://github.com/bling/vim-airline) section:
2929

3030
```vim
3131
function! AirlineInit()
@@ -34,3 +34,18 @@ endfunction
3434
3535
autocmd User AirlineAfterInit call AirlineInit()
3636
```
37+
38+
## Lightline Configuration
39+
40+
To show a codeowner in a [Lightline](https://github.com/itchyny/lightline.vim) section:
41+
42+
```vim
43+
let g:lightline = {
44+
\ 'active': {
45+
\ 'right': [['codeowners']]
46+
\ },
47+
\ 'component_function': {
48+
\ 'codeowners': 'codeowners#whoBufname'
49+
\ },
50+
\ }
51+
```

0 commit comments

Comments
 (0)