In Vim, what is the “alternate file”?

前端 未结 4 690
慢半拍i
慢半拍i 2021-01-01 09:26

I just ran :help registers in Vim and noticed that # \'contains the name of the alternate file\'.

I have seen an example for renaming files

4条回答
  •  不思量自难忘°
    2021-01-01 09:30

    I use it in the buffer context to return to the last buffer that I was editing

    vim foo bar 
    :n 
    :e#
    

    will take you back to foo in that case

提交回复
热议问题