Skip to content

Instantly share code, notes, and snippets.

View Vosjedev's full-sized avatar

Vosjedev

View GitHub Profile
@Vosjedev
Vosjedev / caddy-readme-dirlist.html
Last active September 2, 2023 16:03
readme support for caddy file listing: This is a modification of https://github.com/caddyserver/caddy/blob/e81369e2208e47d9650f9699ad8bc7692640b275/modules/caddyhttp/fileserver/browse.html which if present displays header.html above the directory listing, and if present readme.html below it.
<!DOCTYPE html>
<html>
<head>
<title>{{html .Name}}</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<style>
* { padding: 0; margin: 0; }
body {