summaryrefslogtreecommitdiff
path: root/examples/gopher_fileserver/main.go
diff options
context:
space:
mode:
authortjpcc <tjp@ctrl-c.club>2023-09-07 12:36:17 -0600
committertjpcc <tjp@ctrl-c.club>2023-09-07 12:36:17 -0600
commit38ff3807b3b97da22006b5bdcf03fdfaaa4b0582 (patch)
tree2b66d01de970a14bbf6d9a29acb3a1499c82f9e7 /examples/gopher_fileserver/main.go
parent9330d8546fff5e0397b4eec1a24bf37277a6b745 (diff)
all the gopher CGI handlers to support gophernicus behaviorsv1.3.0
Diffstat (limited to 'examples/gopher_fileserver/main.go')
-rw-r--r--examples/gopher_fileserver/main.go11
1 files changed, 4 insertions, 7 deletions
diff --git a/examples/gopher_fileserver/main.go b/examples/gopher_fileserver/main.go
index 244f61b..057aa21 100644
--- a/examples/gopher_fileserver/main.go
+++ b/examples/gopher_fileserver/main.go
@@ -3,7 +3,6 @@ package main
import (
"context"
"log"
- "os"
sr "tildegit.org/tjp/sliderule"
"tildegit.org/tjp/sliderule/contrib/cgi"
@@ -13,13 +12,11 @@ import (
)
func main() {
- fileSystem := os.DirFS(".")
-
handler := sr.FallthroughHandler(
- fs.GopherDirectoryDefault(fileSystem, "index.gophermap"),
- fs.GopherDirectoryListing(fileSystem, nil),
- cgi.GopherCGIDirectory("/cgi-bin", "./cgi-bin"),
- fs.GopherFileHandler(fileSystem),
+ fs.GopherDirectoryDefault(".", nil),
+ fs.GopherDirectoryListing(".", nil),
+ cgi.GopherCGIDirectory("/cgi-bin", "./cgi-bin", nil),
+ fs.GopherFileHandler(".", nil),
)
_, infoLog, _, errLog := logging.DefaultLoggers()