Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions plugin/vimux.vim
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,8 @@ function! VimuxSendKeys(keys)
endif
endfunction

function! VimuxOpenRunner()
function! VimuxOpenRunner(...)
let l:cmd = exists("a:1") ? ' '.a:1 : ''
let nearestIndex = _VimuxNearestIndex()

if _VimuxOption("g:VimuxUseNearest", 1) == 1 && nearestIndex != -1
Expand All @@ -73,7 +74,7 @@ function! VimuxOpenRunner()
if _VimuxRunnerType() == "pane"
let height = _VimuxOption("g:VimuxHeight", 20)
let orientation = _VimuxOption("g:VimuxOrientation", "v")
call system("tmux split-window -p ".height." -".orientation)
call system("tmux split-window -p ".height." -".orientation.l:cmd)
elseif _VimuxRunnerType() == "window"
call system("tmux new-window")
endif
Expand Down