-
-
Save jvns/6147bc21fbb60b0090d543bb5e240134 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"net/http" | |
"os" | |
) | |
func main() { | |
wd, err := os.Getwd() | |
if err != nil { | |
panic(err) | |
} | |
println("http://localhost:8080/") | |
panic(http.ListenAndServe(":8080", http.FileServer(http.Dir(wd)))) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment