// Package bar handles the main program for i3going-on. // Copyright (C) 2022 Kevin Lyda package bar import ( "bufio" "os" ) type Clicks struct { Button int64 `json:"button"` Modifiers []string `json:"modifiers"` X int64 `json:"x"` Y int64 `json:"y"` RelativeX int64 `json:"relative_x"` RelativeY int64 `json:"relative_y"` Width int64 `json:"width"` Height int64 `json:"height"` } //{"button":1,"modifiers":[],"x":1952,"y":1144,"relative_x":62,"relative_y":14,"width":112,"height":22} func handleCommands() { logger, err := os.Create("/tmp/i3going-on.log") if err != nil { panic(err) } scanner := bufio.NewScanner(os.Stdin) for scanner.Scan() { logger.WriteString(scanner.Text()) } }