]> granicus.if.org Git - vim/commitdiff
updated for version 7.2.394 v7.2.394
authorBram Moolenaar <Bram@vim.org>
Wed, 10 Mar 2010 16:16:12 +0000 (17:16 +0100)
committerBram Moolenaar <Bram@vim.org>
Wed, 10 Mar 2010 16:16:12 +0000 (17:16 +0100)
Problem:    .xz files are not supported.
Solution:   Recognize .xz files so that they can be edited.

runtime/plugin/gzip.vim
src/version.c

index 16e4f8fa03409b1d28484ac546e63dae033d0c1e..edef149537a21d5a305c4502dcaeefe99e69e9b2 100644 (file)
@@ -1,6 +1,6 @@
 " Vim plugin for editing compressed files.
 " Maintainer: Bram Moolenaar <Bram@vim.org>
-" Last Change: 2009 Jul 01
+" Last Change: 2010 Mar 10
 
 " Exit quickly when:
 " - this plugin was already loaded
@@ -20,21 +20,25 @@ augroup gzip
   "
   " Set binary mode before reading the file.
   " Use "gzip -d", gunzip isn't always available.
-  autocmd BufReadPre,FileReadPre       *.gz,*.bz2,*.Z,*.lzma setlocal bin
+  autocmd BufReadPre,FileReadPre       *.gz,*.bz2,*.Z,*.lzma,*.xz setlocal bin
   autocmd BufReadPost,FileReadPost     *.gz  call gzip#read("gzip -dn")
   autocmd BufReadPost,FileReadPost     *.bz2 call gzip#read("bzip2 -d")
   autocmd BufReadPost,FileReadPost     *.Z   call gzip#read("uncompress")
   autocmd BufReadPost,FileReadPost     *.lzma call gzip#read("lzma -d")
+  autocmd BufReadPost,FileReadPost     *.xz  call gzip#read("xz -d")
   autocmd BufWritePost,FileWritePost   *.gz  call gzip#write("gzip")
   autocmd BufWritePost,FileWritePost   *.bz2 call gzip#write("bzip2")
   autocmd BufWritePost,FileWritePost   *.Z   call gzip#write("compress -f")
   autocmd BufWritePost,FileWritePost   *.lzma call gzip#write("lzma -z")
+  autocmd BufWritePost,FileWritePost   *.xz  call gzip#write("xz -z")
   autocmd FileAppendPre                        *.gz  call gzip#appre("gzip -dn")
   autocmd FileAppendPre                        *.bz2 call gzip#appre("bzip2 -d")
   autocmd FileAppendPre                        *.Z   call gzip#appre("uncompress")
   autocmd FileAppendPre                        *.lzma call gzip#appre("lzma -d")
+  autocmd FileAppendPre                        *.xz   call gzip#appre("xz -d")
   autocmd FileAppendPost               *.gz  call gzip#write("gzip")
   autocmd FileAppendPost               *.bz2 call gzip#write("bzip2")
   autocmd FileAppendPost               *.Z   call gzip#write("compress -f")
   autocmd FileAppendPost               *.lzma call gzip#write("lzma -z")
+  autocmd FileAppendPost               *.xz call gzip#write("xz -z")
 augroup END
index 1d90d8944b62ae31c2ea6fb52431e796976e9afd..c799bd8a40ba2a7e804ea19b2e22fabdafac37b2 100644 (file)
@@ -681,6 +681,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    394,
 /**/
     393,
 /**/