Browse Source

couple logging fixes

- log is global array so log can be viewed any time
- log gets written to a defined location ~/.vim-vundle/vundle.log
- TODO: write log changes as they happen
pull/86/merge
gmarik 15 years ago
parent
commit
5c06a28fca
3 changed files with 7 additions and 4 deletions
  1. +1
    -0
      autoload/vundle.vim
  2. +0
    -1
      autoload/vundle/installer.vim
  3. +6
    -3
      autoload/vundle/scripts.vim

+ 1
- 0
autoload/vundle.vim View File

@ -40,5 +40,6 @@ endif
func! vundle#rc(...) abort func! vundle#rc(...) abort
let g:bundle_dir = len(a:000) > 0 ? expand(a:1) : expand('$HOME/.vim/bundle') let g:bundle_dir = len(a:000) > 0 ? expand(a:1) : expand('$HOME/.vim/bundle')
let g:vundle_log = []
call vundle#config#init() call vundle#config#init()
endf endf

+ 0
- 1
autoload/vundle/installer.vim View File

@ -201,7 +201,6 @@ func! s:system(cmd) abort
endf endf
func! s:log(str) abort func! s:log(str) abort
if !exists('g:vundle_log') | let g:vundle_log = [] | endif
call add(g:vundle_log, a:str) call add(g:vundle_log, a:str)
return a:str return a:str
endf endf

+ 6
- 3
autoload/vundle/scripts.vim View File

@ -48,9 +48,12 @@ func! vundle#scripts#setup_view() abort
endf endf
func! s:view_log() func! s:view_log()
if !exists('b:log_file') | let b:log_file = tempname() | endif
call writefile(g:vundle_log, b:log_file)
silent pedit `=b:log_file`
if !exists('g:vundle_log_file')
let g:vundle_log_file = expand('$HOME/.vim-vundle/vundle.log')
endif
call writefile(g:vundle_log, g:vundle_log_file)
silent pedit `=g:vundle_log_file`
wincmd P | wincmd H wincmd P | wincmd H
endf endf


Loading…
Cancel
Save