kevinhwang91 / rnvimr

Make Ranger running in a floating window to communicate with Neovim via RPC
BSD 3-Clause "New" or "Revised" License
804 stars 17 forks source link

Touch to create a new file and press enter will open the file by OS default editor #89

Closed AllenDang closed 3 years ago

AllenDang commented 3 years ago
NVIM v0.6.0-dev+1518-g02bf251bb
Build type: Release
LuaJIT 2.1.0-beta3
Compilation: clang -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1 -DNVIM_TS_HAS_SET_MATCH_LIMIT -O2 -DNDEBUG -Wall -Wextra -pedantic -Wno-unused-parameter -Wstrict-prototypes -std=gnu99 -Wshadow -Wconversion -Wmissing-prototypes -Wimplicit-fallthrough -Wvla -fstack-protector-strong -fno-common -fdiagnostics-color=auto -DINCLUDE_GENERATED_DECLARATIONS -D_GNU_SOURCE -DNVIM_MSGPACK_HAS_FLOAT32 -DNVIM_UNIBI_HAS_VAR_FROM -DMIN_LOG_LEVEL=3 -I/tmp/neovim-20210714-39663-lqn3eb/build/config -I/tmp/neovim-20210714-39663-lqn3eb/src -I/usr/local/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -I/usr/local/opt/gettext/include -I/tmp/neovim-20210714-39663-lqn3eb/build/src/nvim/auto -I/tmp/neovim-20210714-39663-lqn3eb/build/include
编译者 allendang@MacBook-Pro.local

Features: +acl +iconv +tui
See ":help feature-compile"

     系统 vimrc 文件: "$VIM/sysinit.vim"
         $VIM 预设值: "/usr/local/Cellar/neovim/HEAD-02bf251/share/nvim"

Run :checkhealth for more info

Describe the bug

  1. Open ranger inside neovim
  2. :touch init.go to create a file named init.go
  3. Press enter on init.go
  4. OS default editor will be launched.

Expected behavior init.go will be opened by neovim and ranger is closed.

kevinhwang91 commented 3 years ago

FAQ Q: Couldn't open some special types of files by using Enter or l in Ranger.

AllenDang commented 3 years ago

@kevinhwang91 Thing is, I could open a existing go file normally by pressing enter. This issue only happens for file just created by touch command.

kevinhwang91 commented 3 years ago

What is r say?

AllenDang commented 3 years ago

@kevinhwang91 Here is existing file with r 截屏2021-07-20 下午2 47 33

Here is newly created file by :touch with r 截屏2021-07-20 下午2 47 23

kevinhwang91 commented 3 years ago

change your rifle.conf