Initial revision
This commit is contained in:
40
CLASH.system
Normal file
40
CLASH.system
Normal file
@ -0,0 +1,40 @@
|
||||
;;;; -*-Mode: LISP; Package: CL-USER; Syntax: ANSI-Common-lisp -*-
|
||||
;;;; CLASH --- The Common Lisp Adaptable Simple HTTP server
|
||||
;;;; This is copyrighted software. See documentation for terms.
|
||||
;;;;
|
||||
;;;; clash.system --- CLASH system definitions for MK-DEFSYSTEM
|
||||
;;;;
|
||||
;;;; Checkout Tag: $Name$
|
||||
;;;; $Id$
|
||||
|
||||
(in-package :CL-USER)
|
||||
|
||||
;;;; %File Description:
|
||||
;;;;
|
||||
;;;;
|
||||
;;;;
|
||||
|
||||
(defsystem "CLASH-SYS"
|
||||
:source-pathname "src/sys"
|
||||
:source-extension "cl"
|
||||
:components
|
||||
((:file "package")
|
||||
(:file "mp" :depends-on "package")
|
||||
(:file "socket" :depends-on "package")))
|
||||
|
||||
(defsystem "CLASH"
|
||||
:source-pathname "src"
|
||||
:source-extension "cl"
|
||||
:components
|
||||
((:module "base"
|
||||
:source-pathname ""
|
||||
:components ((:file "package")))
|
||||
(:module "main"
|
||||
:source-pathname "main"
|
||||
:components ((:file "url"))
|
||||
:depends-on ("base"))
|
||||
(:module "driver"
|
||||
:source-pathname "drivers"
|
||||
:components ((:file "simple.cl"))
|
||||
:depends-on ("base" "main")))
|
||||
:depends-on ("CLASH-SYS"))
|
||||
25
COPYING
Normal file
25
COPYING
Normal file
@ -0,0 +1,25 @@
|
||||
Copyright (C) 1999 Pierre Mai
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining
|
||||
a copy of this software and associated documentation files (the
|
||||
"Software"), to deal in the Software without restriction, including
|
||||
without limitation the rights to use, copy, modify, merge, publish,
|
||||
distribute, sublicense, and/or sell copies of the Software, and to
|
||||
permit persons to whom the Software is furnished to do so, subject to
|
||||
the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be
|
||||
included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR
|
||||
OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
|
||||
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
||||
OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
Except as contained in this notice, the name of the author shall
|
||||
not be used in advertising or otherwise to promote the sale, use or
|
||||
other dealings in this Software without prior written authorization
|
||||
from the author.
|
||||
55
README
Normal file
55
README
Normal file
@ -0,0 +1,55 @@
|
||||
CLASH - The Common Lisp Adaptable Simple HTTP server
|
||||
====================================================
|
||||
|
||||
This package is a very simple, yet adaptable HTTP server for various
|
||||
implementations of ANSI Common Lisp. Since this package was born out
|
||||
of neccessity ("scratching one's own itch", as Eric Raymond put it in
|
||||
[1]), it provides the following feature set, which might or might not
|
||||
suit your needs:
|
||||
|
||||
* CLASH is as simple as was possible to achieve the given objective of
|
||||
serving static and dynamic content to various new and old clients,
|
||||
as well as allowing for the creation of static snapshots of parts of
|
||||
the served document tree for off-line distribution.
|
||||
|
||||
* It's very adaptable, since I never knew what features would be
|
||||
needed next.
|
||||
|
||||
* It's as portable as possible, requiring only few changes to make it
|
||||
run in other implementations capable of supporting serious HTTP
|
||||
serving.
|
||||
|
||||
* It's under a very unrestrictive and clear licence, mostly X-style.
|
||||
There exist a number of HTTP servers for CL already, but most of
|
||||
them are under licences which are quite vague, and wouldn't stand up
|
||||
in court, thus putting any user under too much of a risk. Since
|
||||
CLASH has been explicitly put in the public domain, this shouldn't
|
||||
be a problem, minus the ever present danger of software patents.
|
||||
|
||||
For information on the conditions of use and copying that come with
|
||||
CLASH, see the file COPYING included in the distribution.
|
||||
|
||||
If CLASH suits your needs, use it as you wish. If it doesn't, take a
|
||||
look at the following packages, which might suit your needs better
|
||||
(and which are quite impressive in their feature sets):
|
||||
|
||||
* CL-HTTP
|
||||
|
||||
This is a very impressive and comprehensive implementation of HTTP
|
||||
(including HTTP/1.1), HTML and XML generation, advanced user
|
||||
interfacing via the WWW, proxying, mirroring, spiders and robots and
|
||||
many other things. It runs in nearly all current implementations.
|
||||
See http://www.ai.mit.edu/projects/iiip/doc/cl-http/home-page.htm
|
||||
|
||||
* Closure
|
||||
|
||||
This is the counter-part of CL-HTTP, in that it is a GPLed web
|
||||
browser. It's still being developed, and although it currently runs
|
||||
only under Franz' Allegro CL (for Linux/Unix), there are plans of
|
||||
porting this further.
|
||||
See http://www.uni-karlsruhe.de/~unk6/closure/
|
||||
|
||||
For further information on the conditions of use and copying that come
|
||||
with CLASH, see the file COPYING included in the distribution.
|
||||
|
||||
For information on building and using CLASH, see doc/README.
|
||||
18
src/package.cl
Normal file
18
src/package.cl
Normal file
@ -0,0 +1,18 @@
|
||||
;;;; CLASH --- The Common Lisp Adaptable Simple HTTP server
|
||||
;;;; This is copyrighted software. See documentation for terms.
|
||||
;;;;
|
||||
;;;; package.cl --- Package definition for CLASH itself
|
||||
;;;;
|
||||
;;;; Checkout Tag: $Name$
|
||||
;;;; $Id$
|
||||
|
||||
(in-package :CL-USER)
|
||||
|
||||
;;;; %File Description:
|
||||
;;;;
|
||||
;;;;
|
||||
;;;;
|
||||
|
||||
(defpackage "CLASH"
|
||||
(:USE :CL :CLASH-SYS)
|
||||
(:EXPORT ))
|
||||
65
tools/init.el
Normal file
65
tools/init.el
Normal file
@ -0,0 +1,65 @@
|
||||
;;;; CLASH --- The Common Lisp Adaptable Simple HTTP server
|
||||
;;;; This is copyrighted software. See documentation for terms.
|
||||
;;;;
|
||||
;;;; init.el -- XEmacs initialisations for the CLASH project
|
||||
;;;;
|
||||
;;;; Checkout Tag: $Name$
|
||||
;;;; $Id$
|
||||
|
||||
;;;; %File Description:
|
||||
;;;;
|
||||
;;;; This pulls together several advanced functions of XEmacs to better
|
||||
;;;; support working with the CLASH project and it's guidelines.
|
||||
;;;; Amongst other things, it provides for automated template insertion
|
||||
;;;; into new files, use of a simple transfer menu/command to switch
|
||||
;;;; between corresponding files, support for CL-Test cases in *.test
|
||||
;;;; files, etc.
|
||||
;;;; To use this file, load it from your .emacs file.
|
||||
;;;;
|
||||
|
||||
;;; Mode-Map
|
||||
(unless (assoc "\\.system$" auto-mode-alist)
|
||||
(push '("\\.system$" . lisp-mode) auto-mode-alist))
|
||||
|
||||
;;; Mode-Defaults
|
||||
(add-hook 'lisp-mode-hook
|
||||
'(lambda ()
|
||||
(setq lisp-indent-offset 76)
|
||||
(put 'with-slots 'lisp-indent-function 2)
|
||||
(put 'with-accessors 'lisp-indent-function 2)
|
||||
(put 'handler-case 'lisp-indent-function 1)))
|
||||
|
||||
;;; Auto-insertion
|
||||
;;(add-hook 'find-file-hooks 'auto-insert)
|
||||
(define-auto-insert "/CLASH/.*\\.cl$"
|
||||
'("Short description: "
|
||||
";;;; CLASH --- The Common Lisp Adaptable Simple HTTP server\n"
|
||||
";;;; This is copyrighted software. See documentation for terms.\n"
|
||||
";;;; \n"
|
||||
";;;; " (file-name-nondirectory (buffer-file-name)) " --- " str "\n"
|
||||
";;;; \n"
|
||||
";;;; Checkout Tag: $" "Name$\n"
|
||||
";;;; $" "Id$\n\n"
|
||||
"(in-package :CLASH)\n\n"
|
||||
";;;; %File Description:\n"
|
||||
";;;; \n"
|
||||
";;;; " _ "\n"
|
||||
";;;; \n\n"))
|
||||
|
||||
(define-auto-insert "/CLASH/.*\\.test$"
|
||||
'(nil
|
||||
";;;; CLASH --- The Common Lisp Adaptable Simple HTTP server\n"
|
||||
";;;; This is copyrighted software. See documentation for terms.\n"
|
||||
";;;; \n"
|
||||
";;;; " (file-name-nondirectory (buffer-file-name)) " --- "
|
||||
"Regression test cases for "
|
||||
(replace-in-string (file-name-nondirectory (buffer-file-name))
|
||||
"\\.test$" ".cl" t)
|
||||
"\n"
|
||||
";;;; \n"
|
||||
";;;; Checkout Tag: $" "Name$\n"
|
||||
";;;; $" "Id$\n\n"
|
||||
";;;; %File Description:\n"
|
||||
";;;; \n"
|
||||
";;;; " _ "\n"
|
||||
";;;; \n\n"))
|
||||
Reference in New Issue
Block a user