Giter VIP home page Giter VIP logo

simplehttpserver's Introduction

SimpleHTTPServer

A small library developed for use in applications to provide output via a webpage.

Made with extensibility and readability in mind. Makes extensive use of C++11.

The provided example will attempt to retrieve the requested file, if it is a lua file, it will process the file and return the output as the webpage. See Data/index.lua.

Lacks support for HTTP1.1 and websockets, only supports GET requests, but it can easily be tailored to specific needs.

Only tested on Windows, Linux may work with some configuration. (Uses SFML-Network, the premake script may need changes to compile on linux)

Installation

Compilation

  • Windows - Visual Studio: Run premake-vs2013.bat, a VS2013 solution will be generated in the Build directory, open up ALL_BUILD.sln and compile.
  • Command line: Alternatively, you can navigate to the Premake directory, and use commands premake gmake or premake.exe vs2010 for Windows. This has the provided benfit of command line options.
  • Clean: Using the premake-clean.sh you can remove all temporary files.
  • Clean-all: Using the premake-clean-all.sh you can remove all temporary and compiled binary files.
Premake actions

The action in premake is the task carried out, it is passed to premake as the first argument: premake5.exe <action>

  • clean Removes all temporary files, removes only temporary files such as build objects. Used by 'premake-clean.sh'
  • clean-all Sterilizes the repo to it's original state, removes all files including compiled binaries. Used by 'premake-clean-all.sh'
  • version Prints out the version of the sources.
  • gen-docs Attempts to create documentation using Doxygen (thereby it should be installed on the system beforehand), output in Bin/Docs.
  • gmake Generates GNU Makefile build scripts*
  • vs2005 Generate project files for VS2005*
  • vs2008 Generate project files for VS2008*
  • vs2010 Generate project files for VS2010*
  • vs2012 Generate project files for VS2012*
  • vs2013 Generate project files for VS2013. Used by 'premake-vs2013.bat'

* Not supported

Installation

After compiling, you probably need to install the libraries (.dll on windows and .so on others), to do this just use the provided install-libraries.bat.

Running the example program

Compile all projects in visual studio, run install-libraries.bat as above, go to Bin folder and run LuaServer.exe. By default the program runs on the 9398 port, so to view the webpage, go to http://localhost:9398

Contact

License

SimpleHTTPServer is licensed under the MIT License

simplehttpserver's People

Contributors

kamilkz avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.