File tree Expand file tree Collapse file tree 1 file changed +1
-14
lines changed
Expand file tree Collapse file tree 1 file changed +1
-14
lines changed Original file line number Diff line number Diff line change 44 "context"
55 "database/sql"
66 "encoding/json"
7- "io/ioutil"
8- "log"
97 "os"
108 "runtime"
119
@@ -31,18 +29,7 @@ func NewApp() *App {
3129func (a * App ) startup (ctx context.Context ) {
3230 home , _ := os .UserHomeDir ()
3331
34- content , err := ioutil .ReadFile ("./wails.json" )
35- if err != nil {
36- log .Fatal ("Error when opening file: " , err )
37- }
38- var payload map [string ]interface {}
39- err = json .Unmarshal (content , & payload )
40- if err != nil {
41- log .Fatal ("Error during Unmarshal(): " , err )
42- }
43- infos := payload ["info" ].(map [string ]interface {})
44-
45- a .version = "v" + infos ["productVersion" ].(string ) + " - " + runtime .GOOS + " - " + runtime .GOARCH
32+ a .version = "v0.2.1" + " - " + runtime .GOOS + " - " + runtime .GOARCH
4633
4734 a .ctx = ctx
4835 if _ , err := os .Stat (home + string (os .PathSeparator ) + ".cheat_sheets.db" ); os .IsNotExist (err ) {
You can’t perform that action at this time.
0 commit comments