Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Web application environment for Common Lisp
Common Lisp Nginx
Failed to load latest commit information.
roswell Fix a symbol conflict of 'TERMINATE' in roswell/clackup.ros. CCL has …
src Fix Clack.Handler.Hunchentoot to be able to run multiple apps. (fixes #…
t Allow to use a random port for each subtest in handler test suites.
tmp forgot to add "tmp" directory, using clack.test.suite.
v1-compat Replace cl-fad by UIOP.
.gitignore Fix JSON middleware to recognize Content-Type that specifies a charse…
.travis.yml Use the latest fast-http for ECL support.
README.markdown Fix README.
clack-handler-fcgi.asd Clean clack-handler-fcgi up.
clack-handler-hunchentoot.asd Clean clack-handler-hunchentoot up.
clack-handler-toot.asd Clean clack-handler-toot up.
clack-handler-wookie.asd Add clack-socket to abstract :clack.io sockets in handlers.
clack-socket.asd Add clack-socket to abstract :clack.io sockets in handlers.
clack-test.asd Move clack-test files.
clack-v1-compat.asd Replace cl-fad by UIOP.
clack.asd Delete test-op of clack.asd.
t-clack-handler-fcgi.asd Move core files.
t-clack-handler-hunchentoot.asd Move core files.
t-clack-handler-toot.asd Move core files.
t-clack-handler-wookie.asd Move core files.
t-clack-v1-compat.asd Add clack.request & clack.response and fix tests.

README.markdown

Clack - Web Application Environment for Common Lisp

Build Status Coverage Status Quicklisp dist

Clack is a web application environment for Common Lisp inspired by Python's WSGI and Ruby's Rack.

Usage

(defvar *handler*
    (clack:clackup
      (lambda (env)
        (declare (ignore env))
        '(200 (:content-type "text/plain") ("Hello, Clack!")))))

Open your web browser and go to http://localhost:5000/. You should get "Hello, Clack!".

To stop the server, use (clack:stop *handler*).

Command-line interface

Clack provides a script to start a web server. It's useful when you deploy to production environment.

NOTE: Install Roswell before as it depends on it.

When you execute ros install clack, it copies clackup script to $HOME/.roswell/bin. Make sure the path is in your shell $PATH.

$ ros install clack
$ which clackup
/Users/nitro_idiot/.roswell/bin/clackup

$ cat <<EOF >> app.lisp
(lambda (env)
  (declare (ignore env))
  '(200 (:content-type "text/plain") ("Hello, Clack!")))
EOF
$ clackup app.lisp
Hunchentoot server is started.
Listening on localhost:5000.

Installation

(ql:quickload :clack)

Documentation

Server

See Also

  • Lack: Clack application builder

Author

Copyright

Copyright (c) 2011-2015 Eitaro Fukamachi & contributors

License

Licensed under the LLGPL License.

Something went wrong with that request. Please try again.