rename to vitrine; relocate under common/
commit 13311ca7001c46943a58436abdf2d274f47fbdfc · parent 1ed81d60bd
· browse this tree
Ximianth, 2026-07-27 23:23:05 UTC
repoview grows up: this tool is about to become reusable across hosts (config file, hostname theming, and a config poller follow in later commits), so it gets a real name -- vitrine: a glass display case; read-only, curated, on show -- and moves to fusion/common/vitrine/, which syncs to other machines. Module, binary, service unit, and UI strings all renamed. No behavior change; URL space and serving semantics untouched. The langoustine deployment was switched over in the same motion (old repoview unit disabled and removed).
diff --git a/go.mod b/go.mod index cf0e751..e94e9e5 100644 --- a/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module repoview +module vitrine go 1.26.5 diff --git a/main.go b/main.go index 6119c10..c0da3cf 100644 --- a/main.go +++ b/main.go @@ -1,4 +1,4 @@ -// Command repoview is a tiny read-only web viewer for local source trees. +// Command vitrine is a tiny read-only web viewer for local source trees. // // Each configured root is served under its name as a URL prefix, // e.g. "/moonshot-1/crates/iri/filetests/verify-errors.md". @@ -32,6 +32,6 @@ func main() { if err != nil { log.Fatal(err) } - log.Printf("repoview listening on %s", *addr) + log.Printf("vitrine listening on %s", *addr) log.Fatal(http.ListenAndServe(*addr, srv)) } diff --git a/render.go b/render.go index f7379c6..94acbff 100644 --- a/render.go +++ b/render.go @@ -62,7 +62,7 @@ func joinURL(mount, rel string) string { // home, then each path segment. The last segment gets no href; // it's the page being viewed. func crumbs(urlpath string) []crumb { - cs := []crumb{{Name: "repoview", Href: "/"}} + cs := []crumb{{Name: "vitrine", Href: "/"}} if urlpath == "" { cs[0].Href = "" return cs diff --git a/repoview.service b/repoview.service deleted file mode 100644 index 136a3eb..0000000 --- a/repoview.service +++ /dev/null @@ -1,11 +0,0 @@ -[Unit] -Description=repoview: tiny read-only web viewer for fusion source trees -After=network.target - -[Service] -ExecStart=/usr/local/bin/repoview -addr :8000 -User=exedev -Restart=on-failure - -[Install] -WantedBy=multi-user.target diff --git a/serve.go b/serve.go index e26828a..ba1aec8 100644 --- a/serve.go +++ b/serve.go @@ -59,7 +59,7 @@ func (s *server) ServeHTTP(w http.ResponseWriter, r *http.Request) { http.Redirect(w, r, r.URL.Path+"/", http.StatusMovedPermanently) return } - title := "repoview" + title := "vitrine" if req != "" { title = req + "/" } diff --git a/style.css b/style.css index 34676d3..3d630b4 100644 --- a/style.css +++ b/style.css @@ -1,4 +1,4 @@ -/* repoview stylesheet. Embedded in the binary; served at /-/style.css. */ +/* vitrine stylesheet. Embedded in the binary; served at /-/style.css. */ :root { --ink: #24292f; diff --git a/vitrine.service b/vitrine.service new file mode 100644 index 0000000..6325d0b --- /dev/null +++ b/vitrine.service @@ -0,0 +1,11 @@ +[Unit] +Description=vitrine: tiny read-only web viewer for fusion source trees +After=network.target + +[Service] +ExecStart=/usr/local/bin/vitrine -addr :8000 +User=exedev +Restart=on-failure + +[Install] +WantedBy=multi-user.target