I installed Smalltalk from source which comes with its own mode. The files smalltalk-mode.el and smalltalk-mode.elc are placed in /usr/local/share/emacs/site-lisp/ and this path is in my load-path but Emacs can not recognize .st files as Smalltalk mode. I also tried (require 'smalltalk-mode) in my init.el, but didn't help. Why is this happening?

  • 1
    smalltalk-mode is probably just not set up to be the default mode for .st files. Try opening one and then doing M-x smalltalk-mode to see if you installed it properly in the first place.
    – user12563
    Mar 8, 2018 at 12:52
  • @DoMiNeLa10 M-x smalltalk-mode activated the mode, i have now colors and Smalltalk activated
    – user12021
    Mar 8, 2018 at 12:57
  • Is there not a commentary section in smalltalk-mode.el with installation instructions? If not, you might raise an issue upstream to have such documentation added.
    – phils
    Mar 8, 2018 at 23:49

1 Answer 1


smalltalk-mode requires configuration to be the default mode for .st files. In order to have it there, you need to add this to your init file:

(add-to-list 'auto-mode-alist '("\\.st\\'" . smalltalk-mode))

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.