Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

List index out of range in _VimuxNearestPaneIndex() #72

Closed
eagle0701 opened this issue Jun 24, 2013 · 0 comments · Fixed by #75
Closed

List index out of range in _VimuxNearestPaneIndex() #72

eagle0701 opened this issue Jun 24, 2013 · 0 comments · Fixed by #75

Comments

@eagle0701
Copy link

After i set tmux pane-base-index to 1, match(panes[i], "(active)") == -1 will case list index out of range.

change

for i in panes
    if match(panes[i], "(active)") == -1
      return split(panes[i], ":")[0]
    endif
endfor

to

for pane in panes
    if match(pane, "(active)") == -1
      return split(pane, ":")[0]
    endif
endfor

and there is no problem.

Thanks for your plugin

daviddavis pushed a commit to daviddavis/vimux that referenced this issue Jul 3, 2013
Fix the following error. This fixes preservim#72.

E684: list index out of range: 1
E116: Invalid arguments for function match(panes[i], "(active)") == -1
E15: Invalid expression: match(panes[i], "(active)") == -1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant