vim 5.3, gzip files, and Debian Slink
Hello I recently discovered that vim allows editing of gzip'd files. However, in my case, this capability is only available on my stock debian installation where I installed the vim package and not on my custom debian installation where I installed/Make'd vim myself. I tried to rebuild/config/make vim with gzip options, but I couldn't find any such option. (I searched for gzip, and gz in the man page of vim, the vim Makefile, vim feature.h, and vim configure but never found it.) I did notice that vim --version on the two machines were slightly different. The most obvious of which was that the stock debian version included a -DDEBIAN switch. I also looked for that define in the vim source config files, but I didn't find it either. Does Debian somehow do something to the gzip files before vim edits them or something? Is magic involved? Many Thanks.
Re: vim 5.3, gzip files, and Debian Slink
On Wed, Sep 15, 1999 at 09:46:28AM -0400, John Davis wrote: Does Debian somehow do something to the gzip files before vim edits them or something? Is magic involved? Look at the vimrc file that comes with the Debian installation of vim. It has the following in it: augroup gzip Remove all gzip autocommands au! Enable editing of gzipped files read: set binary mode before reading the file uncompress text in buffer after reading write: compress file after writing append: uncompress file, append, compress file autocmd BufReadPre,FileReadPre*.gz set bin autocmd BufReadPre,FileReadPre*.gz let ch_save = ch|set ch=2 autocmd BufReadPost,FileReadPost *.gz '[,']!gunzip autocmd BufReadPost,FileReadPost *.gz set nobin autocmd BufReadPost,FileReadPost *.gz let ch = ch_save|unlet ch_save autocmd BufReadPost,FileReadPost *.gz execute :doautocmd BufReadPost . %:r autocmd BufWritePost,FileWritePost*.gz !mv afile afile:r autocmd BufWritePost,FileWritePost*.gz !gzip afile:r autocmd FileAppendPre *.gz !gunzip afile autocmd FileAppendPre *.gz !mv afile:r afile autocmd FileAppendPost*.gz !mv afile afile:r autocmd FileAppendPost*.gz !gzip afile:r augroup END -- Steve C. Lamb | I'm your priest, I'm your shrink, I'm your ICQ: 5107343 | main connection to the switchboard of souls. ---+-
Re: vim 5.3, gzip files, and Debian Slink
Minor magic -- look in /etc/vimrc on your stock debian box. Roughly line 57-104 will be useful to you. :) On Wed, Sep 15, 1999 at 09:46:28AM -0400, John Davis wrote: Hello I recently discovered that vim allows editing of gzip'd files. However, in my case, this capability is only available on my stock debian installation where I installed the vim package and not on my custom debian installation where I installed/Make'd vim myself. I tried to rebuild/config/make vim with gzip options, but I couldn't find any such option. (I searched for gzip, and gz in the man page of vim, the vim Makefile, vim feature.h, and vim configure but never found it.) I did notice that vim --version on the two machines were slightly different. The most obvious of which was that the stock debian version included a -DDEBIAN switch. I also looked for that define in the vim source config files, but I didn't find it either. Does Debian somehow do something to the gzip files before vim edits them or something? Is magic involved? Many Thanks. -- Unsubscribe? mail -s unsubscribe [EMAIL PROTECTED] /dev/null -- Seth Arnold | http://www.willamette.edu/~sarnold/ Hate spam? See http://maps.vix.com/rbl/ for help Hi! I'm a .signature virus! Copy me into your ~/.signature to help me spread!