I'm running Emacs 27.1(9.0) on OSX 11.2.2 and have failed at installing and configuring the package s.el from https://github.com/magnars/s.el/ Here's a list of things that I tried:

  1. Copied s.el into ~/.emacs.d/elisp/
  2. Added (add-to-list 'load-path "/Users/username/.emacs.d/lisp") # replace username with actual username
  3. Verified that emacs does not complain when loading. Running M-x s-trim-<TAB> does not show any of the functions in s.el.
  4. From the mini-buffer, loaded the file using M-x load-file and then typing /Users/username/.emacs.d/lisp/s.el - no errors observed here. However, M-x s-trim<TAB> does not display any functions in s.el
  5. Opened up s.el in emacs, selected the first function s-trim-right and evaluated it with C-x C-e. Even though it evaluated without errors, M-x s-trim<TAB> does not list this function.
  6. Repeat steps 1-5 from terminal by launching emacs with emacs --debug-init

I'm totally lost on how to get this working. The github page https://github.com/magnars/s.el/ says that the package can be installed by running M-x package-install s. However, M-x package-install does not list s as a valid package name. I only see a list of packages that have the letter s in their names.

1 Answer 1


You have loaded s.el properly. The functions you are trying to call aren't interactive, what we call 'commands' in elisp. You can only call them from elisp code, they don't work with M-x.

  • 1
    Good Lord, thanks for clearing that up. I was losing my mind.
    – linuxfan
    Commented Mar 1, 2021 at 3:58

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.