Learning Clojure (2)

Source: Internet
Author: User

工欲善其事, its prerequisite, we need a handy clojure development environment.


Of course, using Clojure's

The simplest way is: command line + Notepad.

Java-jar Clojure-1.8.0.jar

This will start the REPL, interactive environment.

JAVA-CP Clojure-1.8.0.jar Clojure.main

It can be used in this way.


If you have already written a Clojure source program A.CLJ

How to run it: Java-jar Clojure-1.8.0.jar A.CLJ


Instead of typing this much each time, you can do a Clj.bat file:

Java-jar Clojure-1.8.0.jar%1


Later, start REPL:CLJ

Run source file: Clj A.CLJ


Notepad is weak after all, unless you have no choice.

Below use SUBLIMETEXT3 official website to download, can always use freely, function does not reduce, until conscience discovers need to pay.

After installation, start tossing the plugin.

    1. Installing the package Controler

      CTRL + ' (the key above the tab) is pasted into:

Import Urllib.request,os; PF = ' package control.sublime-package '; IPP = Sublime.installed_packages_path (); Urllib.request.install_opener (Urllib.request.build_opener (Urllib.request.ProxyHandler ())); Open (Os.path.join (IPP, PF), ' WB '). Write (Urllib.request.urlopen (' http://sublime.wbond.net/' + pf.replace (', '%20 ')) . Read ())

2.

At this point, Perferences has one more item: Package Control, click

Enter the install packages and wait for the list to be prepared.

Enter Clojure, choose what you need, and wait for the installation to complete.


At this point, you can histograms the parentheses, and the syntax is highlighted.

To compile conveniently, you need one step further:

Menu: Tools | Build System | New build system ....

Input:

"Shell_cmd": "Java-cp d:/sososo/clojure-1.8.0.jar clojure.main $file"

When saving, the name of the first section of the file name is changed to Clojure.

Next Compile press Ctrol+b


Learning Clojure (2)

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.