feat: use go:embed to embed templates (#1756)
This commit is contained in:
12
tools/goctl/api/new/api.tpl
Normal file
12
tools/goctl/api/new/api.tpl
Normal file
@@ -0,0 +1,12 @@
|
||||
type Request {
|
||||
Name string ` + "`" + `path:"name,options=you|me"` + "`" + `
|
||||
}
|
||||
|
||||
type Response {
|
||||
Message string ` + "`" + `json:"message"` + "`" + `
|
||||
}
|
||||
|
||||
service {{.name}}-api {
|
||||
@handler {{.handler}}Handler
|
||||
get /from/:name(Request) returns (Response)
|
||||
}
|
||||
Reference in New Issue
Block a user