Mac OS (Leopard) 上有一个漂亮且简单的 Clojure 安装程序吗?

发布于 2024-09-29 12:55:16 字数 1618 浏览 10 评论 0原文

我找到了以下指南:

http://mark.reid.name/sap/setting -up-clojure.html

但这似乎是一大堆手动步骤,我敢打赌它已经过时了。在 Windows 上安装 ClojureBox 轻而易举。有人知道它的简单安装程序吗?哪里可以下载,步骤是什么?

谢谢!

编辑:尝试安装蛋糕,得到:

$ sudo gem install cake
Password:
ERROR:  While executing gem ... (Gem::RemoteSourceException)
    HTTP Response 302

还尝试使用脚本安装:

$ sudo ./cake_install.rb 
http://github.com/ninjudd/cake-standalone/raw/master/jars/cake-0.5.4.jar
[=============================================================================]
http://build.clojure.org/releases/org/clojure/clojure/1.2.0/clojure-1.2.0.jar
[=============================================================================]
Exception in thread "main" java.lang.UnsupportedClassVersionError: Bad version number in .class file (ordered_set.clj:1)

编辑2:现在Java版本问题:) Java版本我需要吗?在哪里下载?

$ sudo cake test
Exception in thread "main" java.lang.UnsupportedClassVersionError: Bad version number in .class file (ordered_set.clj:1)

我的 Leopard 软件是最新的 :(

Apple Computer supplies their own version of Java. Use the Software Update feature (available on the Apple menu) to check that you have the most up-to-date version of Java for your Mac. If you have problems with downloading, installing or using Java on Mac, please contact Apple Computer Technical Support.

编辑: 嗯...我怀疑我尝试过的建议之一破坏了我在 Apple 上连接到互联网(有线和无线)的能力: (

I found the following guide:

http://mark.reid.name/sap/setting-up-clojure.html

but it seems like a whole lot of manual steps, and I bet it is out of date already. Installing ClojureBox on Windows was a breeze. Does anyone know of a simple installer for it? Where can I download it, and what are the steps?

Thanks!

EDIT: Tried installing cake, got:

$ sudo gem install cake
Password:
ERROR:  While executing gem ... (Gem::RemoteSourceException)
    HTTP Response 302

Also tried installing using the script:

$ sudo ./cake_install.rb 
http://github.com/ninjudd/cake-standalone/raw/master/jars/cake-0.5.4.jar
[=============================================================================]
http://build.clojure.org/releases/org/clojure/clojure/1.2.0/clojure-1.2.0.jar
[=============================================================================]
Exception in thread "main" java.lang.UnsupportedClassVersionError: Bad version number in .class file (ordered_set.clj:1)

EDIT 2: Now the Java version issues :) What version of Java do I need and where to download it?

$ sudo cake test
Exception in thread "main" java.lang.UnsupportedClassVersionError: Bad version number in .class file (ordered_set.clj:1)

My Leopard software is up to date :(

Apple Computer supplies their own version of Java. Use the Software Update feature (available on the Apple menu) to check that you have the most up-to-date version of Java for your Mac. If you have problems with downloading, installing or using Java on Mac, please contact Apple Computer Technical Support.

EDIT: Hm ... I suspect that one of the suggestions I tried broke my ability to connect to the internet (both wired as well as wireless) on Apple :(

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(7

剧终人散尽 2024-10-06 12:55:16

Clojure 也可以通过 Homebrew 安装:

Clojure is also installable via Homebrew:

望她远 2024-10-06 12:55:16

如果您只想运行 clojure 程序,那么 macports 就可以了。请记住,您依赖维护者来更新版本。

如果您计划编写 clojure 程序,那么 cake 是一个更好的起点观点。安装涉及以下其中一项(您的选择):

使用 gem(最简单)

  1. gem install cake

独立脚本

  1. 下载脚本
  2. 将其放在路径中的某个位置,然后chmod +x cake 进行制作它可执行

Git 存储库

  1. git clone git://github.com/ninjudd/cake.git
  2. 将 bin/cake 符号链接到您的路径并使其可执行

Cake 是一个完整的构建系统,但您可以通过运行 Cake repl 使用它来启动 repl。还有leiningen,但是启动 repl 会感觉更快,因为它使用持久性 JVM。

If you just want to run clojure programs, then macports works. Bear in mind you're dependent upon the maintainer to update versions.

If you plan on writing clojure programs, then cake is a better starting point. Installation involves one of the following (your choice):

Using gem (easiest)

  1. gem install cake

Standalone script

  1. Download the script
  2. Put it somewhere in your path and chmod +x cake to make it executable

Git repository

  1. git clone git://github.com/ninjudd/cake.git
  2. Symlink bin/cake into your path and make it executable

Cake is a full build system, but you can just use it to fire up the repl by running cake repl. There's also leiningen, but starting repls will feel faster in cake since it uses persistent JVMs.

云归处 2024-10-06 12:55:16

我发现 Leiningen 非常容易使用。只需下载脚本,将其放在 $PATH 中的某个位置(例如 /usr/bin/)并使其可执行:sudo chmod +x lein
现在输入 lein repl ,Leiningen 将下载您需要的所有文件并为您创建一个 REPL。就是这么简单。

I find Leiningen very easy to use. Just download the script, put it somewhere in your $PATH (/usr/bin/ for example) and make it executable: sudo chmod +x lein.
Now type lein repl and Leiningen will download all the files you need and create a REPL for you. It's that easy.

柒夜笙歌凉 2024-10-06 12:55:16

您可能需要检查CounterClockWise(一个 Eclipse 插件)。 此处有一个有关如何安装它的视频。它将为您提供许多可供使用的功能 - 包括 clojure REPL。

You may want to check CounterClockWise (an Eclipse plugin). There's a video on how to install it here. It'll give you a lot of features to play with - including a clojure REPL.

樱娆 2024-10-06 12:55:16

刚刚检查过这在 Ubuntu 下仍然可以工作。 Mac 应该是一样的,除了使用 mac 使用的任何东西而不是 apt-get 来安装 maven:

http://www.learningclojure.com/2010/08/clojure-emacs-swank-slime-maven-maven.html

你需要安装maven,创建一个文件,然后你可以调用 mvn clojure:repl ,一切都应该正常工作。

如果您还想要整个 emacs-swank-slime 设置,现在也很简单,并在那里进行了描述。

如果您尝试一下,您可以在此处或博客上发表评论,让我知道我是否需要对 Mac 进行任何更改吗?

Just checked this will still work under Ubuntu. It should be the same for macs, except using whatever macs use instead of apt-get to install maven:

http://www.learningclojure.com/2010/08/clojure-emacs-swank-slime-maven-maven.html

You need to install maven, create a file, then you can just call mvn clojure:repl and everything should just work.

If you'd also like the whole emacs-swank-slime setup that's also easy now, and described there.

If you try it can you comment back here or on the blog to let me know if there are any changes I need to make for macs?

來不及說愛妳 2024-10-06 12:55:16

安装 MacPorts,然后运行 ​​sudo port install clojure

Install MacPorts and then run sudo port install clojure

蓝梦月影 2024-10-06 12:55:16

我曾经创建了一个名为 ClojureX 的包,它部分基于 Mark 的文章。它不再被积极维护(至少不是由我维护),但没有理由它不起作用:

http:// github.com/citizen428/ClojureX

I once created a package called ClojureX that was partly based on Mark's article. It's not actively maintained anymore (at least not by me), but there's no reason it wouldn't work:

http://github.com/citizen428/ClojureX

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文