Revanth47 / go-serve

A Command-Line Static File Server using Go

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

go-serve

Command-Line Static File Server

Go Report Card Travis

Usage

How to use it? Just run (Default: serves current working directory on localhost:8000)

$ go-serve

Dont like the port? Then change it

$ go-serve -p 3000

Want to serve only a specific sub directory?

$ go-serve -d assets

Want to serve files through a different public path? (say localhost:8000/files/)?

$ go-serve --path /files/

Other options

$ go-serve --disable-dir // To disable directory listing
$ go-serve --read 10s    // Maximum request read time
$ go-serve --write 10s   // Maximum response write time 

Installation

$ go get -u github.com/Revanth47/go-serve

Contribute

Feel free to send Pull Requests to add/improve upon features or to fix bugs.

LICENSE

MIT

About

A Command-Line Static File Server using Go

License:MIT License


Languages

Language:Go 100.0%