Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do not delete the close pair on <BS> when opening a file by nerdtree #269

Closed
drchen00 opened this issue Feb 12, 2018 · 2 comments
Closed

Comments

@drchen00
Copy link

drchen00 commented Feb 12, 2018

This is my test log
delimitMate Report

* Options: ( ) default, (g) global, (b) buffer

( ) delimitMate_apostrophes = ''
( ) delimitMate_apostrophes_list = []
( ) delimitMate_autoclose = 1
( ) delimitMate_balance_matchpairs = 0
( ) delimitMate_eol_marker = ''
( ) delimitMate_excluded_regions = 'Comment'
( ) delimitMate_excluded_regions_enabled = 1
( ) delimitMate_excluded_regions_list = ['Comment']
(g) delimitMate_expand_cr = 1
( ) delimitMate_expand_inside_quotes = 0
( ) delimitMate_expand_space = 0
( ) delimitMate_insert_eol_marker = 1
(g) delimitMate_jump_expansion = 1
( ) delimitMate_left_delims = ['(', '{', '[']
( ) delimitMate_matchpairs = '(:),{:},[:]'
( ) delimitMate_matchpairs_list = [['(', ')'], ['{', '}'], ['[', ']']]
(b) delimitMate_nesting_quotes = ['"']
( ) delimitMate_quotes = '" '' `'
( ) delimitMate_quotes_list = ['"', '''', '`']
( ) delimitMate_right_delims = [')', '}', ']']
( ) delimitMate_smart_matchpairs = '^\%(\w\|\!\|[£$]\|[^[:punct:][:space:]]\)'
( ) delimitMate_smart_quotes = '\%(\w\|[^[:punct:][:space:]"''`]\|\%(\\\\\)*\\\)\%#\|\%#\%(\w\|[^[:space:][:punct:]"''`]\)'
( ) delimitMate_tab2exit = 1

( ) g:delimitMate_excluded_ft = ''
--------------------

* Mappings:

                                                               i  )            @<Plug>delimitMate)
	最近修改于 ~/.vim/bundle/delimitMate/plugin/delimitMate.vim
i  }            @<Plug>delimitMate}
	最近修改于 ~/.vim/bundle/delimitMate/plugin/delimitMate.vim
i  ]            @<Plug>delimitMate]
	最近修改于 ~/.vim/bundle/delimitMate/plugin/delimitMate.vim
i  (            @<Plug>delimitMate(
	最近修改于 ~/.vim/bundle/delimitMate/plugin/delimitMate.vim
i  {            @<Plug>delimitMate{
	最近修改于 ~/.vim/bundle/delimitMate/plugin/delimitMate.vim
i  [            @<Plug>delimitMate[
	最近修改于 ~/.vim/bundle/delimitMate/plugin/delimitMate.vim
i  "            @<Plug>delimitMate"
	最近修改于 ~/.vim/bundle/delimitMate/plugin/delimitMate.vim
i  '            @<Plug>delimitMate'
	最近修改于 ~/.vim/bundle/delimitMate/plugin/delimitMate.vim
i  `            @<Plug>delimitMate`
	最近修改于 ~/.vim/bundle/delimitMate/plugin/delimitMate.vim
i  <BS>        * <SNR>68_OnDeleteChar( "\<BS>" )
	最近修改于 ~/.vim/bundle/YouCompleteMe/autoload/youcompleteme.vim
i  <S-BS>       @<Plug>delimitMateS-BS
	最近修改于 ~/.vim/bundle/delimitMate/plugin/delimitMate.vim
i  <S-Tab>     * pumvisible() ? "\<C-P>" : "\<S-Tab>"
	最近修改于 ~/.vim/bundle/YouCompleteMe/autoload/youcompleteme.vim
i  <C-G>g       @<Plug>delimitMateJumpMany
	最近修改于 ~/.vim/bundle/delimitMate/plugin/delimitMate.vim
i  <CR>         @<Plug>delimitMateCR
	最近修改于 ~/.vim/bundle/delimitMate/plugin/delimitMate.vim
--------------------

* Showcase:

Open: (|)
Delete: |)
Exit: ()|
Car return: (
|
)
Delete car return: (|
)

Open: {|}
Delete: |}
Exit: {}|
Car return: {
    |
}
Delete car return: {|
}

Open: [|]
Delete: |]
Exit: []|
Car return: [
|
]
Delete car return: [|
]

Open: "|"
Delete: |"
Exit: ""|

Open: '|'
Delete: |'
Exit: ''|

Open: `|`
Delete: |`
Exit: ``|

 * Vim configuration:

filetype detection:ON  plugin:ON  indent:ON

--- 选项 ---
  autochdir           breakindent         cpoptions=aAceFsB   filetype=python     helplang=cn         keywordprg=pydoc    report=0            showcmd             splitbelow          ttyfast
  autoindent          comments=b:#,fb:-   cursorcolumn        foldlevel=1         hlsearch            laststatus=2        ruler               smartcase           splitright          ttymouse=sgr
  autoread            confirm             cursorline          foldlevelstart=1    ignorecase          modified            scroll=29           smartindent         suffixesadd=.py     wildignore=*.pyc
  background=dark     copyindent          expandtab           foldmethod=indent   incsearch           number              shiftwidth=4        softtabstop=4       syntax=python
  backspace=indent,eol,start
  cinkeys=0{,0},0),:,!^F,o,O,e
  commentstring=# %s
  completefunc=youcompleteme#CompleteFunc
  completeopt=menuone
  fileencoding=utf-8
  fileencodings=ucs-bom,utf-8,default,latin1
  include=^\s*\(from\|import\)
  includeexpr=substitute(v:fname,'\.','/','g')
  indentexpr=GetPythonIndent(v:lnum)
  indentkeys=0{,0},:,!^F,o,O,e,<:>,=elif,=except
  omnifunc=pythoncomplete#Complete
  printoptions=paper:a4
  runtimepath=~/.vim,~/.vim/bundle/Vundle.vim,~/.vim/bundle/vim-autoformat,~/.vim/bundle/YouCompleteMe,~/.vim/bundle/syntastic,~/.vim/bundle/vimcdoc,~/.vim/bundle/delimitMate,~/.vim/bundle/nerdcommenter,~/.vim/bundle/nerdtree,~/.vim/bundle/nerdtree-git-plugin,/var/lib/vim/addons,/usr/share/vim/vimfiles,/usr/share/vim/vim74,/usr/share/vim/vimfiles/after,/var/lib/vim/addons/after,~/.vim/after,~/.vim/bundle/Vundle.vim/,~/.vim/bundle/Vundle.vim/after,~/.vim/bundle/vim-autoformat/after,~/.vim/bundle/YouCompleteMe/after,~/.vim/bundle/syntastic/after,~/.vim/bundle/vimcdoc/after,~/.vim/bundle/delimitMate/after,~/.vim/bundle/nerdcommenter/after,~/.vim/bundle/nerdtree/after,~/.vim/bundle/nerdtree-git-plugin/after
  shortmess=filnxtToOc
  statusline= %<%F[%1*%M%*%n%R%H%W]%= %y %0(%{&fileformat} %{&encoding} %l/%L:%c %p%%%) 
  suffixes=.bak,~,.swp,.o,.info,.aux,.log,.dvi,.bbl,.blg,.brf,.cb,.ind,.idx,.ilg,.inx,.out,.toc

VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Nov 24 2016 16:44:48)
包含补丁: 1-1689
另外的补丁: 8.0.0056
修改者 pkg-vim-maintainers@lists.alioth.debian.org
编译者 pkg-vim-maintainers@lists.alioth.debian.org
巨型版本 无图形界面。  可使用(+)与不可使用(-)的功能:
+acl             -clipboard       +dialog_con      +file_in_path    +job             +menu            -mouse_sysmouse  +persistent_undo +scrollbind      -tcl             +visual          -xim
+arabic          +cmdline_compl   +diff            +find_in_path    +jumplist        +mksession       +mouse_urxvt     +postscript      +signs           +terminfo        +visualextra     -xsmp
+autocmd         +cmdline_hist    +digraphs        +float           +keymap          +modify_fname    +mouse_xterm     +printer         +smartindent     +termresponse    +viminfo         -xterm_clipboard
-balloon_eval    +cmdline_info    -dnd             +folding         +langmap         +mouse           +multi_byte      +profile         +startuptime     +textobjects     +vreplace        -xterm_save
-browse          +comments        -ebcdic          -footer          +libcall         -mouseshape      +multi_lang      -python          +statusline      +timers          +wildignore      -xpm
++builtin_terms  +conceal         +emacs_tags      +fork()          +linebreak       +mouse_dec       -mzscheme        +python3         -sun_workshop    +title           +wildmenu        
+byte_offset     +cryptv          +eval            +gettext         +lispindent      +mouse_gpm       +netbeans_intg   +quickfix        +syntax          -toolbar         +windows         
+channel         +cscope          +ex_extra        -hangul_input    +listcmds        -mouse_jsbterm   +packages        +reltime         +tag_binary      +user_commands   +writebackup     
+cindent         +cursorbind      +extra_search    +iconv           +localmap        +mouse_netterm   +path_extra      +rightleft       +tag_old_static  +vertsplit       -X11             
-clientserver    +cursorshape     +farsi           +insert_expand   -lua             +mouse_sgr       -perl            -ruby            -tag_any_white   +virtualedit     -xfontset        
     系统 vimrc 文件: "$VIM/vimrc"
     用户 vimrc 文件: "$HOME/.vimrc"
 第二用户 vimrc 文件: "~/.vim/vimrc"
      用户 exrc 文件: "$HOME/.exrc"
         $VIM 预设值: "/usr/share/vim"
编译方式: gcc -c -I. -Iproto -DHAVE_CONFIG_H   -Wdate-time  -g -O2 -fPIE -fstack-protector-strong -Wformat -Werror=format-security -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1      
链接方式: gcc   -Wl,-Bsymbolic-functions -fPIE -pie -Wl,-z,relro -Wl,-z,now -Wl,--as-needed -o vim        -lm -ltinfo -lnsl  -lselinux  -lacl -lattr -lgpm -ldl     -L/usr/lib/python3.5/config-3.5m-x86_64-linux-gnu -lpython3.5m -lpthread -ldl -lutil -lm      

@Raimondi
Copy link
Owner

That's because youcompleteme has mapped <BS>:

i  <BS>        * <SNR>68_OnDeleteChar( "\<BS>" )
	最近修改于 ~/.vim/bundle/YouCompleteMe/autoload/youcompleteme.vim

@drchen00
Copy link
Author

Yes, the bug is caused by YCM indeed.
https://github.com/Valloric/YouCompleteMe/issues/2696 can fix it.(I also have remaped )

p-herbert pushed a commit to p-herbert/vim-settings that referenced this issue Mar 12, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants