2012-07-19 19 views
1

我試圖讓vimclojure去,並會感謝任何幫助,我做了什麼錯。這裏是一個錯誤,當我嘗試在我的雷音項目之一讀取project.clj:爲什麼nailgun服務器拋出'無法確定文件的命名空間'錯誤?

; Use \p to close this buffer! 

Could not determine the Namespace of the file. 

This might have different reasons. Please check, that the ng server 
is running with the correct classpath and that the file does not contain 
syntax errors. The interactive features will not be enabled, ie. the 
keybindings will not be mapped. 

Reason: 
Error executing Nail! (230) 
connect: Connection refused 

以下是的〜/ .vimrc

filetype off 
call pathogen#runtime_append_all_bundles() 
filetype plugin indent on 
let g:vimclojure#HighlightBuiltins = 1 
let g:vimclojure#ParenRainbow = 1 
let vimclojure#NailgunClient = "/home/cnorton/bin/ng" 
let vimclojure#WantNailgun = 1 
:helptags ~/.vim/bundle/VimClojure/doc/ 

相關線路和nailgun是CLASSPATH

export CLASSPATH=/usr/share/java:/home/cnorton/bin:$CLASSPATH 
export VIMCLOJURE_SERVER_JAR="$HOME/bin/server-2.3.0.jar" 

我錯過了什麼和/或我做錯了什麼? 謝謝。

+0

嘗試使用[lein-tarsier](https://github.com/sattvik/lein-tarsier)來管理nailgun服務器。 – Jeremy 2012-07-20 00:36:16

回答

2
connect: Connection refused 

您沒有啓動服務器。或者錯誤地配置了服務器地址/端口。

+0

你如何啓動nailgun服務器?我試圖 '$ java的com.martiansoftware.nailgun.NGServer 異常線程 「main」 ...... 產生的原因:拋出java.lang.ClassNotFoundException:com.martiansoftware.nailgun.NGServer \t 1 java.net.URLClassLoader的$。運行(URLClassLoader.java:217) \t在java.security.AccessController.doPrivileged(本機方法) \t在java.net.URLClassLoader.findClass(URLClassLoader.java:205) \t在java.lang.ClassLoader.loadClass( ClassLoader.java:321) \t at sun.misc.Launcher $ AppClassLoader.loadClass(Launcher.java:294) \t at java.lang.ClassLoader.loadClass(ClassLoader.java:266) ...' – isomorphismes 2013-02-06 11:13:20

+1

您必須設置類路徑。最低限度是'java -cp clojure.jar:vimclojure-server.jar vimclojure.nailgun.NGServer 127.0.0.1'。 – kotarak 2013-02-06 11:47:56

+0

將jar名稱替換爲機器上罐子的實際位置。 (順便說一下,你可能想要一些像lein-tarsier插件。)(或者你想看看nrepl和vim-foreplay。) – kotarak 2013-02-06 11:49:28

相關問題