Closed hanleylee closed 3 years ago
I can't reproduce, even with those exact options. What Vim version? What netrw version?
Thanks for your patience! After I try many times(in vanilla on MacOS and Linux), I found the reason is set hidden
.
I can't get any output by :echo expand('%')
for the first time -
into netrw
after I add this line to my vimrc, everything will be ok after I remove this line.
Please check it again.
I found you make a new commit for this issue, so I update vim-vinegar
to latest.
Actually, this issue still exists, can you try it again?
I can no longer reproduce the problem. What happens if you do :e %:h
to enter netrw?
If I have file ~/.vim/vimrc
, then I use vim ~/.vim/vimrc
to edit this file, I will get the following result by different action
config | action | echo | result |
---|---|---|---|
set nohidden |
:Explore |
:echo expand('%') |
~/.vim |
set nohidden |
:e %:h |
:echo expand('%') |
~/.vim |
set nohidden |
- |
:echo expand('%') |
~/.vim |
set hidden |
:Explore |
:echo expand('%') |
~/.vim |
set hidden |
:e %:h |
:echo expand('%') |
NONE |
set hidden |
- | :echo expand('%') |
NONE |
I reproduced this by creating a docker image, you can check it https://hub.docker.com/r/hanleylee/test_vinegar
Please provide step by step instructions for using this Docker image. Pretend you're talking to someone who rarely uses Docker.
I encounter a strange issue: when I use
-
go into netrw, I can't get correct output by:echo expand('%')
.If I just use
:Explore
go into netrw, the output for:echo expand('%')
is correct. I already test this by unload all plugin exceptvim-vinegar
. I can confirm it's a bug because ofvim-vinegar
. Following is my configuration: