aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxero <x@xero.nu>2015-05-13 20:48:26 -0400
committerxero <x@xero.nu>2015-05-13 20:48:26 -0400
commit076e2d3ba1691a34b003083e5da0d9a8bef6c386 (patch)
tree4f634ec616bb85d7c6ec77b9a96f48ed8d95ff14
parentcf76948c65eaae4d6c18d6974bb175e2eb2d0c4f (diff)
downloaddotfiles_ascii-076e2d3ba1691a34b003083e5da0d9a8bef6c386.tar.xz
dotfiles_ascii-076e2d3ba1691a34b003083e5da0d9a8bef6c386.zip
add vim json pretty print command
-rw-r--r--vim/.vimrc3
1 files changed, 3 insertions, 0 deletions
diff --git a/vim/.vimrc b/vim/.vimrc
index a194b52..a7ccc6f 100644
--- a/vim/.vimrc
+++ b/vim/.vimrc
@@ -89,6 +89,9 @@ autocmd FileType c,cpp,java,php,js,python,twig,xml,yml autocmd BufWritePre <buff
" make ; work like : for commands. lazy shifting
nnoremap ; :
+" json pretty print
+command J :%!python -mjson.tool
+
" enable file type detection and do language-dependent indenting
if has("autocmd")
filetype on