Release logging to sentry
This commit is contained in:
@@ -23,6 +23,7 @@ func Start(conf common.Conf, dbO *sql.DB) *gin.Engine {
|
||||
|
||||
if conf.SentryDSN != "" {
|
||||
ravenClient, err := raven.New(conf.SentryDSN)
|
||||
ravenClient.SetRelease(common.Version)
|
||||
if err != nil {
|
||||
fmt.Println(err)
|
||||
} else {
|
||||
|
@@ -78,7 +78,7 @@ func MetaUpdateGET(md common.MethodData) common.CodeMessager {
|
||||
if !execCommand("go", "get", "-v", "-u", "-d") {
|
||||
return
|
||||
}
|
||||
if !execCommand("go", "build", "-v", "-o", "api") {
|
||||
if !execCommand("bash", "-c", "go build -v -ldflags \"-X main.Version=`git rev-parse HEAD`\" -o api") {
|
||||
return
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user