What is the difference between .exrc and .vimrc?

vim - What is the difference between .exrc and .vimrc? - Unix & Linux Stack Exchange

My questions are:

  1. What is the difference between .exrc and .vimrc?
  2. If both are present, then are both used?
  3. Is it bad practice to use the .exrc file to configure vim?


Answer:

  1. .exrc is the configuration file for vi, whereas .vimrc is the config file for vim
  2. No. Vim will use the .vimrc file if present, otherwise the .exrc file if present
  3. Yes, unless you only put vi-compatible commands in there