Can't launch `lein` REPL in Emacs

后端 未结 2 2025
感动是毒
感动是毒 2021-02-13 01:26

In Emacs, when using clojure-mode, I ought to be able to launch a REPL with C-c C-z. Whenever I try, though, I get the error:

Searching         


        
2条回答
  •  太阳男子
    2021-02-13 02:14

    I had the same problem and started to investigate what was wrong. I soon discovered my exec-path looked like this (simplified example):

    ("/usr/local/bin /bin /sbin").
    

    It was a list with just one long string instead of a list of separate paths. My env PATH variable looked exactly the same. Obviously the problem was coming from my shell.

    I use fish-shell. It's PATH variable separator is just a space. The exec-path-from-shell package I use can't parse it. I fixed it by appending this to my .emacs.d/init.el:

    (setq exec-path (split-string (car exec-path)))
    

    Update: In the end it was an outdated exec-path-from-shell package. Use version 1.8. It works well with fish (and tcsh).

提交回复
热议问题