update 'rails server' in function rinari-web-server#90
update 'rails server' in function rinari-web-server#90xlisp wants to merge 2 commits intoeschulte:masterfrom xlisp:master
Conversation
|
You use zsh and set PATH in .zshrc? In that case, do not work in the next procedure? M-: (setq ruby-compilation-executable (executable-find "ruby")) In the case of a non-interactive shell, zsh reads /etc/zshenv and .zshenv. When the PATH which is not right is set in either, rinari-web-server does not work. |
Agreed, if that's what's happening here. But it's not clear to me what this patch is trying to do, or why it's necessary. How would I reproduce the problem which this patch fixes? |
|
@purcell thanks :) |
|
@erw7 ➜ ~ echo $PATH
/Users/jim/.rvm/gems/ruby-2.2.0/bin:/Users/jim/.rvm/gems/ruby-2.2.0@global/bin:/Users/jim/.rvm/rubies/ruby-2.2.0/bin:/Library/Java/JavaVirtualMachines/jdk1.8.0_25.jdk/Contents/Home//bin:/Users/jim/bin:/usr/local/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/jim/Downloads/apache-maven-3.2.5//bin:/Users/jim/.rvm/bin
➜ ~ cat .zshenv
export ZSH=$HOME/.oh-my-zsh
ZSH_THEME="robbyrussell"
export PATH=$HOME/bin:/usr/local/bin:$PATH
source $ZSH/oh-my-zsh.shI use your command , I't work good :) , but I don't know how setting in path for Emacs. M-: (setq ruby-compilation-executable (executable-find "ruby"))
M-x rinaria-web-serverAnd my Rspec is no work : M-: (executable-find "rake") # = > "/Users/jim/.rvm/rubies/ruby-2.2.0/bin/rake"
M-: (setq rake-compilation-executable (executable-find "rake"))
M-x rspec-verify-all # rspec-mode, https://github.com/pezra/rspec-mode |
=> PATH set in exec-path of Emacs is used.(run-ruby) => PATH set in /etc/zshenv and ~/.zshenv of zsh is used.(ruby-compilation-run) Therefore I think that PATH set in .zshenv should be used. Is ruby not installed in $HOME/bin or /usr/local/bin? What happens result of the evaluating next code in the *scratch* buffer . May be Rspec work next code. I feel next settings in your init.el that is quick solution. |
|
@erw7 (setq shell-file-name "/bin/bash") |



function rinari-web-server is no run in Rails 4 :)