aboutsummaryrefslogtreecommitdiff
path: root/vim/config/indent.vim
Commit message (Collapse)AuthorAgeFilesLines
* Merge join,indent.vim into whitespace.vimTom Ryder2017-11-101-21/+0
|
* Remove setting for 'tabstop'Tom Ryder2017-11-101-3/+0
| | | | | | | | | | | :help 'tabstop' says that setting it may be a bad idea: > Note: Setting 'tabstop' to any other value than 8 can make your file > appear wrong in many places (e.g., when printing it). On thinking about it, it's actually probably better to show literal tabs as eight screen spaces, as it will make it very obvious when there are tabs in the file.
* Revert dynamic filetype indent configurationTom Ryder2017-10-301-20/+11
| | | | | | | This requires more careful thought to avoid stale local options (:setlocal) for appropriate filetypes. This reverts commit d3d998c68c335b35525172c700ff958d5a016399.
* Configure indent dynamically based on filetypeTom Ryder2017-10-301-11/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a new buffer is created with no filename, it's often because I want to paste text into it without being bothered by autoindent or tab translation, and so I'd rather Vim just accepted the text as literal input without trying to indent it for me. Similarly, for CSV files or Vim help files, space-based automatic indentation is undesirable or not meaningful. It's better to allow Tab to insert literal tab characters in this case, especially if it's a classic Unix-style tab-separated file. However, these settings should definitely be set on buffers which actually do have virtually any other filetype. I don't really like that long `if` condition there--it might be better to find some way to simulate a case/switch structure instead. I originally wanted to include a "negative match" in the `autocmd` definition, which I imagined looking something like this: autocmd FileType '',csv,help,text call FileTypeIndentConfig(&filetype) autocmd FileType !'',csv,help,text call FileTypeIndentConfig(&filetype) However I can't find anything in the Vim :help or by searching online that suggests this is possible. This function-based approach seems good enough for now. This hasn't been tested on old versions of Vim yet.
* Merge `filetype indent` with `filetype plugin`Tom Ryder2017-10-291-5/+0
| | | | | | | While it would be ideal to keep the indentation-related configuration in the config/indent.vim file, that approach ends up double-loading filetype.vim from the core, so we'll merge them into a single call in config/file.vim instead.
* Move indent .vimrc config into subfileTom Ryder2017-10-281-0/+29