Is there a way to tell Vim from command line to run a specific command after running the vimrc, but before loading a file?
vim --cmd <cmd> <file>runs
<cmd>before loading vimrc,
vim -c <cmd> <file>runs
<cmd>after loading vimrc and after opening the file.
Is there a middle-ground?
In case of an XY problem, this is what I'm trying to achieve.
I'm trying to use Vim to open and edit a huge file (~50GB). I have enough RAM to load the file, but not enough disk space and bandwidth for any sort of extra temporary files. My vimrc enables backups, swap files and undo files by default, and I'd like to find a way to disable all three for a specific Vim invocation. This needs to be done before the file is opened (otherwise a swap file will be created), but after vimrc is loaded (otherwise vimrc is going to override the settings).