mirror of
https://github.com/jbranchaud/til
synced 2026-01-06 16:48:01 +00:00
Add Toggling Syntax Highlighting as a vim til
This commit is contained in:
@@ -7,7 +7,7 @@ variety of languages and technologies. These are things that don't really
|
|||||||
warrant a full blog post. These are mostly things I learn by pairing with
|
warrant a full blog post. These are mostly things I learn by pairing with
|
||||||
smart people at [Hashrocket](http://hashrocket.com/).
|
smart people at [Hashrocket](http://hashrocket.com/).
|
||||||
|
|
||||||
_387 TILs and counting..._
|
_388 TILs and counting..._
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
@@ -459,6 +459,7 @@ _387 TILs and counting..._
|
|||||||
- [Swapping Split Windows](vim/swapping-split-windows.md)
|
- [Swapping Split Windows](vim/swapping-split-windows.md)
|
||||||
- [Tabs To Spaces](vim/tabs-to-spaces.md)
|
- [Tabs To Spaces](vim/tabs-to-spaces.md)
|
||||||
- [The Vim Info File](vim/the-vim-info-file.md)
|
- [The Vim Info File](vim/the-vim-info-file.md)
|
||||||
|
- [Toggling Syntax Highlighting](vim/toggling-syntax-highlighting.md)
|
||||||
- [Unloading A Buffer](vim/unloading-a-buffer.md)
|
- [Unloading A Buffer](vim/unloading-a-buffer.md)
|
||||||
- [Use Active Window With BufExplorer](vim/use-active-window-with-bufexplorer.md)
|
- [Use Active Window With BufExplorer](vim/use-active-window-with-bufexplorer.md)
|
||||||
- [Verbose Commits With Fugitive](vim/verbose-commits-with-fugitive.md)
|
- [Verbose Commits With Fugitive](vim/verbose-commits-with-fugitive.md)
|
||||||
|
|||||||
19
vim/toggling-syntax-highlighting.md
Normal file
19
vim/toggling-syntax-highlighting.md
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
# Toggling Syntax Highlighting
|
||||||
|
|
||||||
|
Syntax highlighting in Vim is generally a good thing, but sometimes you need
|
||||||
|
to turn it off. This can be achieved with the `syntax` command.
|
||||||
|
|
||||||
|
```vim
|
||||||
|
:syntax off
|
||||||
|
```
|
||||||
|
|
||||||
|
When you need that syntax highlighting back again, you can turn it right
|
||||||
|
back on like so:
|
||||||
|
|
||||||
|
```vim
|
||||||
|
:syntax on
|
||||||
|
```
|
||||||
|
|
||||||
|
See `:h syntax-on` for more details.
|
||||||
|
|
||||||
|
h/t Steve Klabnik
|
||||||
Reference in New Issue
Block a user