readme
This commit is contained in:
28
README.md
28
README.md
@ -3,22 +3,20 @@
|
||||
[](https://david-dm.org/75lb/local-web-server)
|
||||

|
||||
|
||||
local-web-server
|
||||
================
|
||||
#local-web-server
|
||||
Fires up a simple, CORS-enabled, static web server on a given port. Use for local web development or file sharing (directory browsing enabled).
|
||||
|
||||

|
||||
|
||||
Install
|
||||
-------
|
||||
##Install
|
||||
Ensure [node.js](http://nodejs.org) is installed first. Linux/Mac users may need to run the following commands with `sudo`.
|
||||
|
||||
##Globally
|
||||
###Globally
|
||||
```sh
|
||||
$ npm install -g local-web-server
|
||||
```
|
||||
|
||||
##Deployed with your project
|
||||
###Deployed with your project
|
||||
```sh
|
||||
$ npm install local-web-server --save-dev
|
||||
```
|
||||
@ -46,8 +44,7 @@ $ npm install
|
||||
$ npm start
|
||||
```
|
||||
|
||||
Usage
|
||||
-----
|
||||
##Usage
|
||||
```
|
||||
Usage
|
||||
$ ws <server options>
|
||||
@ -110,8 +107,7 @@ Or silence:
|
||||
$ ws -f none
|
||||
```
|
||||
|
||||
Storing default options
|
||||
-----------------------
|
||||
##Storing default options
|
||||
To store per-project options, saving you the hassle of inputting them everytime, store them in the `local-web-server` property of your project's `package.json`:
|
||||
```json
|
||||
{
|
||||
@ -147,15 +143,6 @@ To view your stored defaults, run:
|
||||
$ ws --config
|
||||
```
|
||||
|
||||
##Deploy the web server with your project
|
||||
It's quite common to see a set of installation instructions like this:
|
||||
|
||||
```sh
|
||||
$ npm install
|
||||
$ npm install -g
|
||||
```
|
||||
|
||||
|
||||
##Use with Logstalgia
|
||||
local-web-server is compatible with [logstalgia](http://code.google.com/p/logstalgia/).
|
||||
|
||||
@ -174,8 +161,7 @@ $ ws -f logstalgia | logstalgia -
|
||||
|
||||

|
||||
|
||||
Use with glTail
|
||||
---------------
|
||||
##Use with glTail
|
||||
To use with [glTail](http://www.fudgie.org), write your log to disk using the "default" format:
|
||||
```sh
|
||||
$ ws -f default > web.log
|
||||
|
Reference in New Issue
Block a user