Compare commits
No commits in common. "go-2.4.0" and "main" have entirely different histories.
5
go.mod
5
go.mod
@ -1,5 +0,0 @@
|
|||||||
module example.com/hello
|
|
||||||
|
|
||||||
go 1.17
|
|
||||||
|
|
||||||
require github.com/OpenFunction/functions-framework-go v0.5.0
|
|
||||||
17
hello.go
17
hello.go
@ -1,17 +0,0 @@
|
|||||||
package hello
|
|
||||||
|
|
||||||
import (
|
|
||||||
"fmt"
|
|
||||||
"net/http"
|
|
||||||
|
|
||||||
"github.com/OpenFunction/functions-framework-go/functions"
|
|
||||||
)
|
|
||||||
|
|
||||||
func init() {
|
|
||||||
functions.HTTP("Main", Main,
|
|
||||||
functions.WithFunctionPath("/"))
|
|
||||||
}
|
|
||||||
|
|
||||||
func Main(w http.ResponseWriter, r *http.Request) {
|
|
||||||
fmt.Fprintf(w, "Hello, world!\n")
|
|
||||||
}
|
|
||||||
Loading…
Reference in New Issue
Block a user