Is there a way to rename an open file in Emacs? While I\'m viewing it? Something like save-as, but the original one should go away.
Emacs 26.3 (2020-04-03) has rename-file function which can be invoked using M-x rename-file for renaming the current file or any other file for that matter.
rename-file
M-x rename-file