goyo.vim icon indicating copy to clipboard operation
goyo.vim copied to clipboard

Conflict with BufAdd and BufNewFile autocommands in my .vimrc

Open Whyglobaleyes opened this issue 2 years ago • 0 comments

Prior to submitting a new issue make sure to complete these steps:

  • [x] Checkout the dev branch and confirm the issue is present there as well. The dev branch contains fixes that may not have been merged to master yet. I don't know how to use the dev branch - but happy to learn

  • [x] Post the syntax you are using (default/mediawiki/markdown) and your vimwiki settings from your .vimrc markdown :: the problematic .vimrc line is: :au BufAdd,BufNewFile * nested tab sball

  • [x] Provide a detailed description of the problem including steps to reproduce the issue. Below

  • [x] Include the output of :VimwikiShowVersion. Stable version: 2.5


There's a conflict between Goyo and the config line above (error msg below). Goyo works perfectly when I comment the line in my .vimrc .

I found that auto-command somewhere and it puts every new buffer into a new tab which I really like.

Can anyone suggest how to keep the new tab behaviour but avoid applying it to Goyo please - or something similar I was thinking of wrapping Goyo into a function that disables the new tab behaviour but I don't know how to do that. Thanks in advance for any help.


"[No Name]" --No lines in buffer--
Error detected while processing function goyo#execute[7]..<SNR>72_goyo_on:
line   87:
"[No Name]" --No lines in buffer--
line   88:
"[No Name]" --No lines in buffer--
line   89:
"[No Name]" --No lines in buffer--
line   90:
E121: Undefined variable: t:goyo_pads
Error detected while processing function goyo#execute[7]..<SNR>72_goyo_on[92]..<SNR>72_resize_pads:
line    5:
E121: Undefined variable: t:goyo_dim
E116: Invalid arguments for function s:const(t:goyo_dim.width, 2, &columns)
line    6:
E121: Undefined variable: t:goyo_dim
E116: Invalid arguments for function s:const(t:goyo_dim.height, 2, &lines)
line    8:
E121: Undefined variable: t:goyo_dim
E116: Invalid arguments for function max([0, (&lines - t:goyo_dim.height) / 2 - 1])
line    9:
E121: Undefined variable: t:goyo_dim
E116: Invalid arguments for function s:const(t:goyo_dim.yoff, - vmargin, vmargin)
line   10:
E121: Undefined variable: vmargin
line   11:
E121: Undefined variable: vmargin
line   12:
E121: Undefined variable: t:goyo_pads
E116: Invalid arguments for function <SNR>72_setup_pad
line   13:
E121: Undefined variable: t:goyo_pads
E116: Invalid arguments for function <SNR>72_setup_pad
line   16:
E121: Undefined variable: t:goyo_dim
line   17:
E121: Undefined variable: width
E116: Invalid arguments for function max([0, (&columns - width) / 2 - 1])
line   18:
E121: Undefined variable: t:goyo_dim
E116: Invalid arguments for function s:const(t:goyo_dim.xoff, - hmargin, hmargin)
line   19:
E121: Undefined variable: t:goyo_pads
E116: Invalid arguments for function <SNR>72_setup_pad
line   20:
E121: Undefined variable: t:goyo_pads
E116: Invalid arguments for function <SNR>72_setup_pad
Press ENTER or type command to continue

Whyglobaleyes avatar Feb 08 '22 10:02 Whyglobaleyes