Clack

Common Lisp 的 web 服务器抽象层。「Web server abstraction layer for Common Lisp」

Github stars Tracking Chart

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

How to contribute

See CONTRIBUTING.md.

See Also

  • Lack: Clack application builder

Author

Copyright (c) 2011-2015 Eitaro Fukamachi & contributors

License

Licensed under the LLGPL License.

Overview

Name With Ownerfukamachi/clack
Primary LanguageCommon Lisp
Program languageCommon Lisp (Language Count: 1)
Platform
License:MIT License
Release Count13
Last Release Name12.06.0 (Posted on )
First Release Name11.06.0 (Posted on )
Created At2011-01-12 09:24:58
Pushed At2023-11-09 09:55:04
Last Commit At2023-11-09 09:54:22
Stargazers Count1k
Watchers Count69
Fork Count86
Commits Count1.2k
Has Issues Enabled
Issues Count121
Issue Open Count29
Pull Requests Count62
Pull Requests Open Count3
Pull Requests Close Count5
Has Wiki Enabled
Is Archived
Is Fork
Is Locked
Is Mirror
Is Private
To the top