Skip to content

Instantly share code, notes, and snippets.

View in3xes's full-sized avatar

Pradeep Kumar Gayam in3xes

View GitHub Profile
@in3xes
in3xes / ABOUT.md
Created February 23, 2019 18:12 — forked from laobubu/ABOUT.md
A very simple HTTP server in C, for Unix, using fork()

Pico HTTP Server in C

This is a very simple HTTP server for Unix, using fork(). It's very easy to use

How to use

  1. include header httpd.h
  2. write your route method, handling requests.
  3. call serve_forever("12913") to start serving on port 12913
;; Reformat hard-wrapped regions
(defun reformat-hard-wrap (beg end)
(interactive "r")
(shell-command-on-region beg end "fmt -w2000" nil t))