Windows 7 Emacs Compile Command in Cygwin Bash Shell To ensure that Windows 7 Emacs uses the Cygwin Bash shell when executing the compile command (M-x compile) and to ensure that Bash reads the .bashrc, do the following: (setq shell-file-name "bash") (setq shell-command-switch "-ic")