MCPcopy
hub / github.com/hoisie/web

github.com/hoisie/web @v0.1.0 sqlite

repository ↗ · DeepWiki ↗ · release v0.1.0 ↗
105 symbols 272 edges 8 files 13 documented · 12%
README

web.go

web.go is the simplest way to write web applications in the Go programming language.

Overview

web.go should be familiar to people who've developed websites with higher-level web frameworks like sinatra, pylons, or web.py. It is designed to be a lightweight web framework that doesn't impose any scaffolding on the user. Some features include:

  • Routing to url handlers based on regular expressions
  • User sessions
  • Support for fastcgi and scgi
  • Web applications are compiled to native code. This means very fast execution and page render speed ( benchmarks coming soon :)

Installation

  1. Make sure you have the a working Go environment. See the install instructions
  2. git clone git://github.com/hoisie/web.go.git
  3. cd web.go && make install

Example

package main

import (
    "web"
)

func hello(val string) string { return "hello " + val }

func main() {
    web.Get("/(.*)", hello)
    web.Run("0.0.0.0:9999")
}

To run the application, put the code in a file called hello.go and run:

8g hello.go && 8l -o hello hello.8 && ./hello

You can point your browser to http://localhost:9999/world .

Documentation

For a quickstart guide, check out web.go's home page

There is also a tutorial

If you use web.go, I'd greatly appreciate a quick message about what you're building with it. This will help me get a sense of usage patterns, and helps me focus development effors on features that people will actually use.

About

web.go was written by Michael Hoisie.

Follow me on Twitter!

Extension points exported contracts — how you extend this code

Core symbols most depended-on inside this repo

Write
called by 39
web.go
WriteString
called by 16
web.go
String
called by 11
web.go
SetHeader
called by 9
web.go
Get
called by 7
web.go
Close
called by 5
web.go
StartResponse
called by 5
web.go
Abort
called by 5
web.go

Shape

Function 51
Method 39
Struct 13
Interface 1
TypeAlias 1

Languages

Go100%

Modules by API surface

web.go42 symbols
web_test.go23 symbols
fcgi.go16 symbols
request.go11 symbols
scgi.go8 symbols
servefile.go2 symbols
examples/hello.go2 symbols
examples/arcchallenge.go1 symbols

For agents

$ claude mcp add web \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact