File tree 2 files changed +4
-1
lines changed
2 files changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -3,6 +3,7 @@ package main
3
3
import (
4
4
"log"
5
5
"os"
6
+ "time"
6
7
7
8
"github.com/deepsourcelabs/cli/command"
8
9
v "github.com/deepsourcelabs/cli/version"
22
23
)
23
24
24
25
func main () {
25
-
26
26
log .SetFlags (log .LstdFlags | log .Lshortfile )
27
27
28
28
// Init sentry
@@ -38,6 +38,7 @@ func main() {
38
38
// TODO: Handle exit codes here
39
39
pterm .Error .Println (err )
40
40
sentry .CaptureException (err )
41
+ sentry .Flush (2 * time .Second )
41
42
os .Exit (1 )
42
43
}
43
44
}
Original file line number Diff line number Diff line change 7
7
"io/ioutil"
8
8
"os"
9
9
"strings"
10
+ "time"
10
11
11
12
"github.com/deepsourcelabs/cli/utils"
12
13
"github.com/getsentry/sentry-go"
@@ -30,6 +31,7 @@ func NewCmdReport() *cobra.Command {
30
31
Args : utils .NoArgs ,
31
32
Run : func (cmd * cobra.Command , args []string ) {
32
33
returnCode := opts .Run ()
34
+ sentry .Flush (2 * time .Second )
33
35
defer os .Exit (returnCode )
34
36
},
35
37
}
You can’t perform that action at this time.
0 commit comments