[vim/vim] Error detected while processing WinEnter Autocommands for "*"..function <SNR>38_HandleOnlyWindow[13]..<SNR>38_CloseWindow (Issue #13949)

9 views
Skip to first unread message

lijh8

unread,
Feb 1, 2024, 9:45:00 AM2/1/24
to vim/vim, Subscribed

Steps to reproduce

Hi, i'm using vim with nerdtree and tagbar.
with both nerdtree and tagbar toggled on, when i quit editing my last c++ source file, there's this error.

Error detected while processing WinEnter Autocommands for "*"..function <SNR>38_HandleOnlyWindow[13]..<SNR>38_CloseWindow:
line   21:
E1312: Not allowed to change the window layout in this autocmd


this is ~/.vimrc:


set expandtab
set hlsearch
set nowrapscan
set shiftwidth=4
set smartindent
set tabstop=4
syntax off

" NERDTree
autocmd BufEnter * if tabpagenr('$') == 1 && winnr('$') == 1 && exists('b:NERDTree') && b:NERDTree.isTabTree() | quit | endif
autocmd BufEnter * if winnr('$') == 1 && exists('b:NERDTree') && b:NERDTree.isTabTree() | quit | endif
autocmd VimEnter * NERDTree
let g:NERDTreeNodeDelimiter = "\u00a0"
nnoremap <leader>n :NERDTreeFocus<CR> " \ - n
nnoremap <C-n> :NERDTree<CR>          " Ctrl - n
nnoremap <C-t> :NERDTreeToggle<CR>    " Ctrl - t
nnoremap <C-f> :NERDTreeFind<CR>

" tagbar
filetype on            " Tagbar: Filetype detection is turned off, skipping plugin
let g:tagbar_sort = 0  " order of position
nmap <F8> :TagbarToggle<CR>

Screen.Shot.2024-02-01.at.22.33.58.png (view on web)
Screen.Shot.2024-02-01.at.22.34.04.png (view on web)

Expected behaviour

Do not know whether it's related to nerdtree, tagbar, or vim.

Version of Vim

VIM - Vi IMproved 9.0 (2022 Jun 28, compiled Oct 27 2023 01:00:56)

Environment

OS: macOS 12.7.3 (21H1015)

$ uname -a
Darwin ljhs-Mac.local 21.6.0 Darwin Kernel Version 21.6.0: Sun Dec 17 22:55:27 PST 2023; root:xnu-8020.240.18.706.2~1/RELEASE_X86_64 x86_64

$ echo $TERM
xterm-256color

$ echo $SHELL
/bin/zsh
$

Logs and stack traces

No response


Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/13949@github.com>

Christian Brabandt

unread,
Feb 1, 2024, 10:08:07 AM2/1/24
to vim/vim, Subscribed

Check the output of :scriptnames. Nr 38. that is where you should report this issue


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/13949/1921546034@github.com>

Christian Brabandt

unread,
Feb 3, 2024, 4:05:26 AM2/3/24
to vim/vim, Subscribed

Closed #13949 as not planned.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issue/13949/issue_event/11692145406@github.com>

Tapok

unread,
4:49 AM (11 hours ago) 4:49 AM
to vim/vim, Subscribed
Bobik3310 left a comment (vim/vim#13949)

Use :qall/:wall instead of :q/:w


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/13949/3350748745@github.com>

Reply all
Reply to author
Forward
0 new messages