Skip to content

Allow exclude files with no 'filetype' set #122

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

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion autoload/indent_guides.vim
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ endfunction
" Detect if any of the buffer filetypes should be excluded.
"
function! indent_guides#exclude_filetype()
for ft in split(&ft, '\.')
for ft in split(&ft, '\.', 1)
if index(g:indent_guides_exclude_filetypes, ft) > -1
return 1
end
Expand Down
6 changes: 4 additions & 2 deletions doc/indent_guides.txt
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,8 @@ Default: 0. Values: 0 or 1.

------------------------------------------------------------------------------
*'indent_guides_exclude_filetypes'*
Use this option to specify a list of filetypes to disable the plugin for.
Use this option to specify a list of filetypes to disable the plugin for. Use
'' for files with no filetypes set.

Default: ['help']. Values: list of strings.
>
Expand Down Expand Up @@ -265,8 +266,9 @@ Bug reports, feedback, suggestions etc are welcomed.
7. CHANGELOG *indent-guides-changelog*

1.8 (pending release)~
* Allow exclude files with no 'filetype' set (thanks @noscript).
* Added option g:|indent_guides_soft_pattern| to control the pattern for
soft indentation (thanks @sergey-vlasov).
soft indentation (thanks @noscript).
* Added option g:|indent_guides_default_mapping| to control whether the
default mapping (<Leader>ig) gets set (thanks @suy).
* Set size of indent guide to `tabstop` value when `shiftwidth=0` or
Expand Down