Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    mac10688
    @mac10688
    I think it's working now
    mac10688
    @mac10688
    I don't know how I'm supposed to use it now
    I suppose call dein#add({githubname})?
    mac10688
    @mac10688
    I think I found the real readme in the doc folder
    Gontran Baerts
    @gbcreation

    I have added on_event feature.

    Thank you Shougo. I'm gonna test it.

    Gontran Baerts
    @gbcreation

    on_eventseems to work very well. Good work Shougo :+1:
    For vim-diminactive, I'm using the example given in the help file. It works well for :split.
    For vim-projectionist, I'm using this:

    call dein#add('RomainEndelin/vim-projectionist', {
    \    'on_event': ['VimEnter', 'BufRead'],
    \    'on_if': 'findfile(".projections.json", ";") != "" || findfile(".projections.json", ".;") != ""'
    \ })

    I think on_eventdoes not need to handle {list} type, as this seems to work too:

    call dein#add('RomainEndelin/vim-projectionist', {
    \    'on_event': 'VimEnter,BufRead',
    \    'on_if': 'findfile(".projections.json", ";") != "" || findfile(".projections.json", ".;") != ""'
    \ })
    Gontran Baerts
    @gbcreation
    Is it possible to know which event is emitted ?
    I would like to use something like:
    'on_if': 'findfile(".projections.json", event == 'VimEnter' ? ";" : ".;") != ""'
    Gontran Baerts
    @gbcreation
    I answer me, this seems to work:
    call dein#add('RomainEndelin/vim-projectionist', {
    \    'on_event': ['VimEnter', 'BufRead'],
    \    'on_if': 'findfile(".projections.json", a:event == "VimEnter" ? ";" : ".;") != ""'
    \ })
    Wang Shidong
    @wsdjeg
    @Shougo on_i is deprecated.but when it will be delete?
    I now just using on_i feature
    Wang Shidong
    @wsdjeg
    anyone like this feature?
    type any item to open the github repo page of the plugin
    Alexander Jeurissen
    @alexanderjeurissen
    Somehow the following hook doesn't work when using loadstate
      call dein#add('chriskempson/base16-vim', {
            \ 'hook_source': "
            \   colorscheme base16-solarized\n
            \   set background=dark\n
            \"})
    I expect that the colorscheme is applied, but sometimes when i run neovim the default colorscheme is applied.
    If I clear the cache of dein manually using call dein#clear_state() then the next time neovim is run the hook above works as expected, however when I exit that neovim instance and rerun neovim (then I presume dein loads the state because it was previously saved) the hook above isn't executed.
    Alexander Jeurissen
    @alexanderjeurissen
    I just replaced hook_source with hook_add and that seems to solve the problem, but I'm not sure why.. Is it because hook_source is cached and not evaluated in load_state ?
    Shougo
    @Shougo
    @Shougo on_i is deprecated.but when it will be delete?
    Not in the plan. The feature is converted to on_event.
    I just replaced hook_source with hook_add and that seems to solve the problem, but I'm not sure why.. Is it because hook_source is cached and not evaluated in load_state ?
            Note: non lazy plugins' |dein-options-hook_source| cannot be
            called.  You must call it by |dein#call_hook()| if needed.
    Alexander Jeurissen
    @alexanderjeurissen
    Hmm so my previous understanding was that hook_source got called when a plugin is sourced, and hook_add when a dein#add statement is called as in when the plugin is added to the runtime.
    how come non lazy plugins their hook_source is not called, is it because it's impossible for denite to determine when they are sourced ?
    Shougo
    @Shougo
    You can call it manually after dein#end().
    Alexander Jeurissen
    @alexanderjeurissen
    but then what is the benefit of hook_source compared to hook_add ?
    Shougo
    @Shougo
    call dein#call_hook('source')
    Alexander Jeurissen
    @alexanderjeurissen
    should I only use hook_source for actions that require the plugin to be fully loaded and use hook_add for all other cases ?
    or are there other benefits of the hook_source ?
    Shougo
    @Shougo
    You should use hook_source for it.
    hook_add is executed when it is added.
    Alexander Jeurissen
    @alexanderjeurissen
    ok that's what I assumed was the case, so then when should I use hook_add ? in what circumstances ?
    Shougo
    @Shougo
    It is for the mapping configurations for lazy loaded plugins.
    Alexander Jeurissen
    @alexanderjeurissen
    but wouldn't the configuration options of lazy loaded plugins benefit more from being loaded when the plugin is sourced ? i.e. hook_source ?
    Shougo
    @Shougo
    hook_add is the configuration to load it.
    My example:
    [[plugins]]
    repo = 'Shougo/vimfiler.vim'
    depends = 'unite.vim
    on_map = [['n', '<Plug>']]
    on_if = "isdirectory(bufname('%'))"
    hook_add = 'nnoremap <silent>   [Space]v   :<C-u>VimFiler -invisible<CR>'
    hook_source = 'source ~/.vim/rc/plugins/vimfiler.rc.vim'
    The mapping must be defined in hook_add.
    Mike Hartington
    @mhartington
    anyone getting errors when installing a new plugin? It seems that dein and airline aren't playing nice together
    Error detected while processing function airline#check_mode[45]..airline#highlighter#highlight:
    line   14:
    E716: Key not present in Dictionary: accents, accent)
    only seems to happen when you install a new plugin with this
      if dein#check_install()
        call dein#install()
      endif
    see line 73
    I also use dein with airline together,but if I add new plugin,and restart nvim,the plugin will auto install,after installing ,the nvim will be open ,but I can not see color in statusline,
    I need restart neovim
    Mike Hartington
    @mhartington
    yeah thats thing I'm seeing
    Wang Shidong
    @wsdjeg
    I have test in vim ,no issue,only happened in neovim
    @mhartington I think an issue maybe should be open. "airline lost color after dein check install plugin when neovim startup."
    Mike Hartington
    @mhartington