summaryrefslogtreecommitdiff
path: root/client/main.go
diff options
context:
space:
mode:
Diffstat (limited to 'client/main.go')
-rw-r--r--client/main.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/client/main.go b/client/main.go
index 5b88117..c9da6c3 100644
--- a/client/main.go
+++ b/client/main.go
@@ -2,6 +2,7 @@ package main
import (
"citrons.xyz/talk/tui"
+ "citrons.xyz/talk/client/clipboard"
"time"
"fmt"
"os"
@@ -10,6 +11,8 @@ import (
var globalApp *application
func main() {
+ go clipboard.DiscoverCommand()
+
err := tui.Start()
if err != nil {
fmt.Fprintln(os.Stderr, "error initializing terminal: ", err)
@@ -39,6 +42,10 @@ func main() {
globalApp.show()
redraw = false
}
+ case text := <-globalApp.activePaste:
+ globalApp.onPaste(text)
+ globalApp.activePaste = nil
+ redraw = true
}
if globalApp.quit == true {
return