2016-08-25 113 views
1

新的Linux(centos7),新lighttable,新的雷音,新项目:无法理解defproject?

clojure.lang.Compiler $ CompilerException:了java.lang.RuntimeException:无法解析符号:defproject在这种情况下,编译:(/home/zzz/nnn/lighttable/project.clj:1:1)

这是项目:

(defproject lighttable "0.1.0-SNAPSHOT" 
    :description "FIXME: write description" 
    :url "http://example.com/FIXME" 
    :license {:name "Eclipse Public License" 
       :url "http://www.eclipse.org/legal/epl-v10.html"} 
    :dependencies [[org.clojure/clojure "1.8.0"]]) 

经过几年努力的Clojure的,有一个项目,是在刺。 (当然不是这个):我错过了什么?

+0

你是想以任何方式运行你的project.clj,或者你是否已经将它作为源的一部分?该文件不应该直接运行(基本上),但'lein'将其作为描述来执行。 – cfrick

回答

2

你可以从干净的目录再试一次吗?这似乎是为我工作:

~/tmp9 > lein new app lighttable 
Generating a project called lighttable based on the 'app' template. 
~/tmp9 > cd lighttable 
~/tmp9/lighttable > lein run 
Hello, World! 
~/tmp9/lighttable > cat project.clj 
(defproject lighttable "0.1.0-SNAPSHOT" 
    :description "FIXME: write description" 
    :url "http://example.com/FIXME" 
    :license {:name "Eclipse Public License" 
      :url "http://www.eclipse.org/legal/epl-v10.html"} 
    :dependencies [[org.clojure/clojure "1.8.0"]] 
    :main ^:skip-aot lighttable.core 
    :target-path "target/%s" 
    :profiles {:uberjar {:aot :all}}) 

我注意到你有两个:url条目,缺少一些其他的东西。你是否使用命令lein new app lighttable创建它?

+1

第二个':url'格式不佳 – cfrick

0

突然,它没有任何明显的原因运行。