Permalink
Browse files

Allow configure size of quickfix and tmux panel (#162)

  • Loading branch information...
1 parent f1d0a5e commit a54f2c5e18b8c2aad8c6f8ba474760e70fdaaca3 @pbogut pbogut committed with Aug 30, 2016
Showing with 4 additions and 2 deletions.
  1. +2 −1 autoload/dispatch.vim
  2. +2 −1 autoload/dispatch/tmux.vim
@@ -850,7 +850,8 @@ endfunction
function! s:open_quickfix(request, copen) abort
let was_qf = &buftype ==# 'quickfix'
- execute 'botright' (a:copen ? 'copen' : 'cwindow')
+ let height = get(g:, 'dispatch_quickfix_height', 10)
+ execute 'botright' (a:copen ? 'copen'.height : 'cwindow'.height)
if &buftype ==# 'quickfix' && !was_qf && a:copen != 1
wincmd p
endif
@@ -47,12 +47,13 @@ function! dispatch#tmux#make(request) abort
\ (pipepane ? [a:request.expanded . '; echo $? > ' . a:request.file . '.complete'] : [])))
let title = shellescape(get(a:request, 'title', get(a:request, 'compiler', 'make')))
+ let height = get(g:, 'dispatch_tmux_height', 10)
if get(a:request, 'background', 0)
let cmd = 'new-window -d -n '.title
elseif has('gui_running') || empty($TMUX) || (!empty(''.session) && session !=# system('tmux display-message -p "#S"')[0:-2])
let cmd = 'new-window -n '.title
else
- let cmd = 'split-window -l 10 -d'
+ let cmd = 'split-window -l '.height.' -d'
endif
let cmd .= ' ' . dispatch#shellescape('-P', '-t', session.':', 'exec ' . script)

0 comments on commit a54f2c5

Please sign in to comment.