YutaForSayu/yhttps ? reverse-engineered prompt

Reverse engineered prompt

Build me a small native command line app in Rust that works like a super simple local web server for static sites and built frontend apps.

I want one binary I can run on Linux, macOS, Windows, and Termux, with two easy commands, one for serving a file or folder, and one for serving a build folder with clean URLs and an index fallback for single page apps. It should be zero config by default, show useful request logs, and let me turn logging off or change the format if needed.

Please also include handy options for port, host address, gzip and brotli compression, CORS, browser open, cache control, HTTPS with self signed certs or my own cert and key, basic auth, custom headers, proxying API requests, directory listings, and clean URL extensions. Make sure it handles 304 responses, range requests, and blocks path traversal safely. If you need to check current docs for anything, do that too.

Are you gonna build this?

make sure you review the code using coderabbit

Try freeSponsored — opens CodeRabbit in a new tab