starting to work

Signed-off-by: Jeff Carr <jcarr@wit.com>
This commit is contained in:
Jeff Carr 2024-01-12 11:39:36 -06:00
parent 23fa94cbcd
commit a870d3bc76
2 changed files with 7 additions and 2 deletions

View File

@ -16,8 +16,12 @@ func okHandler(w http.ResponseWriter, r *http.Request) {
tmp = r.URL.String()
url, repourl := findkey(tmp)
log.Info("url =", url, "repo url =", repourl)
if repourl != "" {
doGui(w, url, repourl)
return
}
if tmp == "/test" {
// findFile(w)
findFile(w)
return
}
if tmp == "/gui" {

View File

@ -23,7 +23,8 @@ import (
</html>
*/
func doGui(w http.ResponseWriter, path string) {
func doGui(w http.ResponseWriter, gourl string, realurl string) {
fmt.Fprintln(w, "go repo =", gourl, "real url =", realurl)
fmt.Fprintln(w, "<!DOCTYPE html>")
fmt.Fprintln(w, "<html>")
fmt.Fprintln(w, "<head>")