Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Surprisingly file .bashrc_custom has Fundamental mode even though files .bashrc and .bash_profile in the same directory have (Shell-script[bash]).
How can I configure major mode for .bashrc_custom?
把它放到你的 Emacs 初始化文件中:
(add-to-list 'auto-mode-alist '("\\.bashrc_custom\\'" . sh-mode))
注意可能目录局部变量在这里没有受到质疑,它由一个读取字符串的列表统治。匹配文件名的正则表达式。