SkillAgentSearch skills...

Wtri

Haxe/Sys web server

Install / Use

/learn @tong/Wtri
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

WTRI

Embeddable haxe/sys web server.

Usage

new wtri.Server((req,res)-> {
    Sys.println(req.path);
    res.end('Hello!');
}).listen(8080);

See: Wtri.hx

Build

Clone and install dependencies:

git clone https://github.com/tong/wtri.git
cd wtri/
haxelib install haxelib.json
haxelib dev wtri .

Build for various targets:

haxe wtri.hxml -hl wtri.hl
haxe wtri.hxml -hl out/main.c -D hlgen.makefile=make
haxe wtri.hxml -neko wtri.n
haxe wtri.hxml -cpp cpp
haxe wtri.hxml -python wtri.py
haxe wtri.hxml -lua wtri.lua -D lua-vanilla -D lua-jit
haxe wtri.hxml --jvm wtri.jar

Run

wtri --help

Usage: wtri [options]

[--host] <name>      : Address to bind
[--port] <number>    : Port to bind
[--root] <path>      : File system root
[--deflate] <level>  : Enable deflate content encoding
[--uv] <connections> : Use libuv (hl)
[--hscript]          : Enable hcript handler
[--quiet]            : Disable logging to stdout
[--help]             : Print this help

Run directly as an initialization macro:

haxe -lib wtri --macro 'Wtri.start(8080)'

Build

View on GitHub
GitHub Stars40
CategoryDevelopment
Updated7mo ago
Forks9

Languages

Haxe

Security Score

67/100

Audited on Sep 3, 2025

No findings