Automatically determine major-mode for new buffers