{"action":"created","issue":{"url":"https://api.github.com/repos/oblitum/YouCompleteMe/issues/10","labels_url":"https://api.github.com/repos/oblitum/YouCompleteMe/issues/10/labels{/name}","comments_url":"https://api.github.com/repos/oblitum/YouCompleteMe/issues/10/comments","events_url":"https://api.github.com/repos/oblitum/YouCompleteMe/issues/10/events","html_url":"https://github.com/oblitum/YouCompleteMe/issues/10","id":93491961,"number":10,"title":"smartindent not working consistently when using this fork","user":{"login":"puremourning","id":10584846,"avatar_url":"https://avatars.githubusercontent.com/u/10584846?v=3","gravatar_id":"","url":"https://api.github.com/users/puremourning","html_url":"https://github.com/puremourning","followers_url":"https://api.github.com/users/puremourning/followers","following_url":"https://api.github.com/users/puremourning/following{/other_user}","gists_url":"https://api.github.com/users/puremourning/gists{/gist_id}","starred_url":"https://api.github.com/users/puremourning/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/puremourning/subscriptions","organizations_url":"https://api.github.com/users/puremourning/orgs","repos_url":"https://api.github.com/users/puremourning/repos","events_url":"https://api.github.com/users/puremourning/events{/privacy}","received_events_url":"https://api.github.com/users/puremourning/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-07-07T09:59:32Z","updated_at":"2015-07-11T21:41:51Z","closed_at":"2015-07-11T21:37:25Z","body":"Hi,\r\n\r\nI'm a big fan of the changes in this fork, and have been using them for a while. However, I've noticed a very strange behaviour related to \"smartindent\" functionality and files with (strangely!) a \".cfg\" extension. I was so perplexed by this that I created a reduced test case. Here's what I did:\r\n\r\n1. Create a new user with empty home directory\r\n2. Install vundle (git clone https://github.com/gmarik/Vundle.vim.git ~/.vim/bundle/Vundle.vim)\r\n3. Create a .vimrc just installing this fork of YouCompleteMe\r\n\r\n```\r\nset nocompatible              \" be iMproved, required\r\nfiletype off                  \" required\r\n\r\n\" set the runtime path to include Vundle and initialize\r\nset rtp+=~/.vim/bundle/Vundle.vim\r\ncall vundle#begin()\r\n\" alternatively, pass a path where Vundle should install plugins\r\n\"call vundle#begin('~/some/path/here')\r\n\r\n\" let Vundle manage Vundle, required\r\nPlugin 'gmarik/Vundle.vim'\r\n\r\nPlugin 'oblitum/YouCompleteMe'\r\n\r\n\" All of your Plugins must be added before the following line\r\ncall vundle#end()            \" required\r\nfiletype plugin indent on    \" required\r\n\" To ignore plugin indent changes, instead use:\r\n\"filetype plugin on\r\n\r\nsyn on\r\nset smartindent autoindent\r\n```\r\n4. buld the ycm support libs (my build of llvm/clang is trunk revision 239029)\r\n5. edit a file ```vim xyz.cfg``` and observe that closing \"}\" don't unindent when filetype is set to \"cfg\"\r\n6. change to filetype \"text\" and observe that closing \"}\" does indent\r\n\r\n![oblitum-cfg](https://cloud.githubusercontent.com/assets/10584846/8543737/f7857a2a-2496-11e5-9c5a-6005f4523938.gif)\r\n\r\n7. disable YCM and repeat 5 - see that it works\r\n\r\n![oblitum-disabled](https://cloud.githubusercontent.com/assets/10584846/8543757/21bacc96-2497-11e5-9e54-258e12b2bf32.gif)\r\n\r\nI'm totally stumped. Any ideas?\r\n\r\nFWIW i tested this with upstream Valloric's YouCompleteMe and it works correctly.\r\n\r\nCheers,\r\nBen\r\n\r\n\r\n```\r\nvim version 7.4.701\r\n\r\nVIM - Vi IMproved 7.4 (2013 Aug 10, compiled Apr 15 2015 17:44:49)\r\nIncluded patches: 1-701\r\nCompiled by benj@<host>\r\nHuge version with X11-Motif GUI.  Features included (+) or not (-):\r\n+acl             +dialog_con_gui  +insert_expand   +mouse_sgr       -ruby            +vertsplit\r\n+arabic          +diff            +jumplist        -mouse_sysmouse  +scrollbind      +virtualedit\r\n+autocmd         +digraphs        +keymap          +mouse_urxvt     +signs           +visual\r\n+balloon_eval    -dnd             +langmap         +mouse_xterm     +smartindent     +visualextra\r\n+browse          -ebcdic          +libcall         +multi_byte      -sniff           +viminfo\r\n++builtin_terms  +emacs_tags      +linebreak       +multi_lang      +startuptime     +vreplace\r\n+byte_offset     +eval            +lispindent      -mzscheme        +statusline      +wildignore\r\n+cindent         +ex_extra        +listcmds        +netbeans_intg   -sun_workshop    +wildmenu\r\n+clientserver    +extra_search    +localmap        +path_extra      +syntax          +windows\r\n+clipboard       +farsi           -lua             -perl            +tag_binary      +writebackup\r\n+cmdline_compl   +file_in_path    +menu            +persistent_undo +tag_old_static  +X11\r\n+cmdline_hist    +find_in_path    +mksession       +postscript      -tag_any_white   +xfontset\r\n+cmdline_info    +float           +modify_fname    +printer         -tcl             +xim\r\n+comments        +folding         +mouse           +profile         +terminfo        +xsmp_interact\r\n+conceal         -footer          +mouseshape      +python          +termresponse    +xterm_clipboard\r\n+cryptv          +fork()          +mouse_dec       -python3         +textobjects     -xterm_save\r\n+cscope          +gettext         -mouse_gpm       +quickfix        +title           +xpm\r\n+cursorbind      -hangul_input    -mouse_jsbterm   +reltime         +toolbar\r\n+cursorshape     +iconv           +mouse_netterm   +rightleft       +user_commands\r\n   system vimrc file: \"$VIM/vimrc\"\r\n     user vimrc file: \"$HOME/.vimrc\"\r\n 2nd user vimrc file: \"~/.vim/vimrc\"\r\n      user exrc file: \"$HOME/.exrc\"\r\n  system gvimrc file: \"$VIM/gvimrc\"\r\n    user gvimrc file: \"$HOME/.gvimrc\"\r\n2nd user gvimrc file: \"~/.vim/gvimrc\"\r\n    system menu file: \"$VIMRUNTIME/menu.vim\"\r\n  fall-back for $VIM: \"/<redacted>/share/vim\"\r\nCompilation:\r\ngcc -c -I. -Iproto -DHAVE_CONFIG_H -DFEAT_GUI_MOTIF     -g -O2 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1\r\nLinking: gcc   -L/usr/local/lib -Wl,--as-needed -o vim  -lXp -lXmu -lXext -lXm -lXt -lSM -lICE -lXt -lX11 -lSM -\r\nlICE -ldl  -lm -ltinfo -lelf -lnsl  -lselinux  -ldl    -L/usr/lib/python2.6/config -lpython2.6\r\n```\r\n\r\nllvm\r\n\r\n```\r\nsvn info\r\nPath: .\r\nURL: http://llvm.org/svn/llvm-project/llvm/trunk\r\nRepository Root: http://llvm.org/svn/llvm-project\r\nRepository UUID: 91177308-0d34-0410-b5e6-96231b3b80d8\r\nRevision: 239029\r\nNode Kind: directory\r\nSchedule: normal\r\nLast Changed Author: whitequark\r\nLast Changed Rev: 239029\r\nLast Changed Date: 2015-06-04 10:09:53 +0100 (Thu, 04 Jun 2015)\r\n```\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/oblitum/YouCompleteMe/issues/comments/120663053","html_url":"https://github.com/oblitum/YouCompleteMe/issues/10#issuecomment-120663053","issue_url":"https://api.github.com/repos/oblitum/YouCompleteMe/issues/10","id":120663053,"user":{"login":"oblitum","id":1269815,"avatar_url":"https://avatars.githubusercontent.com/u/1269815?v=3","gravatar_id":"","url":"https://api.github.com/users/oblitum","html_url":"https://github.com/oblitum","followers_url":"https://api.github.com/users/oblitum/followers","following_url":"https://api.github.com/users/oblitum/following{/other_user}","gists_url":"https://api.github.com/users/oblitum/gists{/gist_id}","starred_url":"https://api.github.com/users/oblitum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/oblitum/subscriptions","organizations_url":"https://api.github.com/users/oblitum/orgs","repos_url":"https://api.github.com/users/oblitum/repos","events_url":"https://api.github.com/users/oblitum/events{/privacy}","received_events_url":"https://api.github.com/users/oblitum/received_events","type":"User","site_admin":false},"created_at":"2015-07-11T21:41:50Z","updated_at":"2015-07-11T21:41:50Z","body":"thanks for the detailed report."}}