Skip to content

Commit 9f74bcd

Browse files
committed
Port it to new appengine yaml syntax/requirements
1 parent 311cb36 commit 9f74bcd

File tree

3 files changed

+7
-8
lines changed

3 files changed

+7
-8
lines changed

app.yaml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
1-
application: nopullrequests
2-
version: 1
3-
runtime: go
4-
api_version: go1
1+
runtime: go112
52

63
handlers:
74
- url: /static
@@ -16,4 +13,4 @@ handlers:
1613
upload: static/home.html
1714

1815
- url: /.*
19-
script: _go_app
16+
script: auto

nopr.go

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
// TODO: use gorilla sessions instead of Google auth
77
// TODO: xsrf everywhere
88

9-
package nopr
9+
package main
1010

1111
import (
1212
"encoding/json"
@@ -39,7 +39,9 @@ var scopes = strings.Join([]string{
3939
// "repo:status", // permission to add statuses to commits
4040
}, ",")
4141

42-
func init() {
42+
func main() {
43+
appengine.Main()
44+
4345
http.HandleFunc("/start", startHandler)
4446
http.HandleFunc(redirectURLPath, oauthHandler)
4547
http.HandleFunc("/user", userHandler)

templates.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package nopr
1+
package main
22

33
import "html/template"
44

0 commit comments

Comments
 (0)