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.
Yes, with dired mode, you can:
C-x d to open diredRET to select directory of current fileC-x C-j (dired-jump to the name of the current file, in Dired)R to rename the file (or dired-do-rename). q to go back to the (renamed) file bufferThe rename is equivalent to a shell mv, but it will also update any open buffers, and unlike mv it will not change the access and modify times on the file in the filesystem.