示例#1
0
文件: _main.py 项目: sh1mc/dotfiles
def main(serveraddr):
    vim = attach_vim(serveraddr)
    from denite.child import Child
    from denite.util import error_tb
    stdout = sys.stdout
    sys.stdout = RedirectStream(lambda data: vim.out_write(data))
    sys.stderr = RedirectStream(lambda data: vim.err_write(data))
    try:
        child = Child(vim)
        child.main_loop(stdout)
    except Exception as exc:
        error_tb(vim, 'Error in child: %r' % exc)
示例#2
0
class SyncParent(_Parent):
    def _start_process(self):
        from denite.child import Child
        self._child = Child(self._vim)

    def _put(self, name, args):
        return self._child.main(name, args, queue_id=None)
示例#3
0
class SyncParent(_Parent):
    def _start_process(self) -> None:
        from denite.child import Child
        self._child = Child(self._vim)

    def _put(self, name: str, args: typing.List[typing.Any]) -> str:
        return self._child.main(name, args, queue_id=None)  # type: ignore

    def _get(self,
             name: str,
             args: typing.List[typing.Any],
             is_async: bool = False) -> typing.Any:
        return self._put(name, args)
示例#4
0
 def _start_process(self) -> None:
     from denite.child import Child
     self._child = Child(self._vim)
示例#5
0
文件: parent.py 项目: skeept/dotvim
 def _start_process(self):
     from denite.child import Child
     self._child = Child(self._vim)