File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- set -e
1+ set -ex
22
3- npm install
3+ yarn install
44yarn serve
Original file line number Diff line number Diff line change @@ -9,7 +9,13 @@ import (
99)
1010
1111func Init () {
12- logrus .SetFormatter (& logrus.JSONFormatter {
12+ SetFormatter (logrus .StandardLogger ())
13+
14+ logrus .SetLevel (logrus .DebugLevel )
15+ }
16+
17+ func SetFormatter (logger * logrus.Logger ) {
18+ logger .SetFormatter (& logrus.JSONFormatter {
1319 FieldMap : logrus.FieldMap {
1420 logrus .FieldKeyTime : "time" ,
1521 logrus .FieldKeyLevel : "severity" ,
@@ -18,10 +24,8 @@ func Init() {
1824 })
1925
2026 if isLocalEnv , _ := strconv .ParseBool (os .Getenv ("LOCAL_ENV" )); isLocalEnv {
21- logrus .SetFormatter (& prefixed.TextFormatter {
27+ logger .SetFormatter (& prefixed.TextFormatter {
2228 ForceFormatting : true ,
2329 })
2430 }
25-
26- logrus .SetLevel (logrus .DebugLevel )
2731}
Original file line number Diff line number Diff line change 55 "net"
66 "os"
77
8+ "github.com/ThreeDotsLabs/wild-workouts-go-ddd-example/internal/common/logs"
89 grpc_middleware "github.com/grpc-ecosystem/go-grpc-middleware"
910 grpc_logrus "github.com/grpc-ecosystem/go-grpc-middleware/logging/logrus"
1011 grpc_ctxtags "github.com/grpc-ecosystem/go-grpc-middleware/tags"
@@ -13,7 +14,11 @@ import (
1314)
1415
1516func init () {
16- grpc_logrus .ReplaceGrpcLogger (logrus .NewEntry (logrus .StandardLogger ()))
17+ logger := logrus .New ()
18+ logs .SetFormatter (logger )
19+ logger .SetLevel (logrus .WarnLevel )
20+
21+ grpc_logrus .ReplaceGrpcLogger (logrus .NewEntry (logger ))
1722}
1823
1924func RunGRPCServer (registerServer func (server * grpc.Server )) {
Original file line number Diff line number Diff line change 99 },
1010 "dependencies" : {
1111 "@babel/compat-data" : " ^7.9.0" ,
12+ "@babel/core" : " ^7.18.2" ,
1213 "@fullcalendar/core" : " ^4.4.2" ,
1314 "@fullcalendar/daygrid" : " ^4.4.2" ,
1415 "@fullcalendar/interaction" : " ^4.4.0" ,
1516 "@fullcalendar/list" : " ^4.4.0" ,
1617 "@fullcalendar/timegrid" : " ^4.4.0" ,
1718 "@fullcalendar/vue" : " ^4.4.0" ,
19+ "babel-loader" : " ^8.2.5" ,
1820 "bootstrap" : " ^4.4.1" ,
1921 "core-js" : " ^3.22.6" ,
2022 "firebase" : " ^7.14.0" ,
2830 "vue" : " ^2.6.11" ,
2931 "vue-router" : " ^3.1.6" ,
3032 "vue-toast-notification" : " ^0.2.0" ,
31- "vuejs-dialog" : " ^1.4.1"
33+ "vuejs-dialog" : " ^1.4.1" ,
34+ "@babel/preset-env" : " ^7.10.2"
3235 },
3336 "devDependencies" : {
3437 "@vue/cli-plugin-babel" : " ~4.2.0" ,
You can’t perform that action at this time.
0 commit comments