My .vimrc file has filetype mappings for different filetypes such as :
autocmd FileType sh map gf ... autocmd FileType ruby map gf ...
While rewriting a program from one language to another, I have 2 splits, one with a shell script and one with ruby. I would assume that "gf" would take on its mapping based on filetype. However, it can only hold one mapping at a time.
Is there any way to declare a mapping only for the existing file/window. I tried ":windo" and ":bufdo" but they work for all windows or buffers.