Skip to content

Commit

Permalink
Add deoplete compatability
Browse files Browse the repository at this point in the history
  • Loading branch information
cazador481 committed Aug 18, 2015
1 parent 60b39ac commit 5537c45
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 0 deletions.
1 change: 1 addition & 0 deletions ftplugin/perl/perlomni.vim
Original file line number Diff line number Diff line change
Expand Up @@ -767,6 +767,7 @@ endf

" util function for building completion hashlist
fun! s:toCompHashList(list,menu)
return a:list
return map( a:list , '{ "word": v:val , "menu": "'. a:menu .'" }' )
endf

Expand Down
Binary file not shown.
22 changes: 22 additions & 0 deletions rplugin/python3/deoplete/sources/perlomni.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
from .base import Base

import deoplete.util
class Source(Base):
def __init__(self, vim):
Base.__init__(self,vim)
self.name = 'PerlOmni',
self.mark ='[O]'

def gather_candidates(self,context):

type=self.vim.eval("&filetype")
if type != "perl":
return []

val=self.vim.eval("PerlComplete(1,'')")
if val < 1:
return []
values=self.vim.eval("PerlComplete(0,'')")
self.vim.command("echo '"+','.join(values)+"'")

return [{'word': x } for x in values]
Empty file modified utils/find_base_classes.pl
100644 → 100755
Empty file.
Empty file modified utils/moose-type-constraints
100644 → 100755
Empty file.
Empty file modified utils/parse_moose_accessor.pl
100644 → 100755
Empty file.

0 comments on commit 5537c45

Please sign in to comment.