A Leiningen template for a minimal WAMP WebSocket server with HTTP Kit and clj-wamp.
Create a new clj-wamp project with leiningen:
% lein new clj-wamp my-project-name
% cd my-project-name
% lein run
...and open browser to localhost:8080
wamptutorial
├── README.md
├── project.clj
├── resources
│ └── public
│ └── index.html
├── resources-dev
│ ├── config.clj
│ └── log4j.properties
└── src
└── wamptutorial
├── config.clj
├── main.clj
├── routes.clj
└── websocket.clj
One-time setup:
- Clone this repo
- Add the following to your
~/.lein/profiles.clj
user plugins:[clj-wamp/lein-template "0.1.0-SNAPSHOT"]
Test/Dev cycle:
- Run
lein install
- In a temp directory, run
lein new clj-wamp testcljwamp
- Try running the new project:
lein run
Template code is based off of HTTP Kit's lein template.
Copyright © 2013 Christopher Martin
Distributed under the Eclipse Public License, the same as Clojure.