surv

    1.0.0 • Public • Published

    surv

    A global npm package much like Python's SimpleHTTPServer.

    1. Serves static files (index.html by default)
    2. Provides 'dev' logging via morgan

    Install

    $ npm install -g surv
    

    Usage

    $ cd the/dir/you/want/to/serve
    
    /the/dir/you/want/to/serve $ surv [port]
    

    Examples

    Assuming you want to serve files from your public directory:

    /public $ surv 3333
    surv is serving /public at http://localhost:3333
    

    If omitted the port will default to 3000.

    /public $ surv
    surv is serving /public at http://localhost:3000
    

    Use 0 for a random port.

    /public $ surv 0
    surv is serving /public at http://localhost:RANDOM_PORT_NUMBER
    

    ISC License (ISC)

    Copyright 2014, Instancetype

    Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies.

    THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

    Install

    npm i surv

    DownloadsWeekly Downloads

    6

    Version

    1.0.0

    License

    ISC

    Last publish

    Collaborators

    • instancetype