Some echo tests added.
This commit is contained in:
1 parent
8a32895457
commit
eb5b2038d6
38 files changed
+1739
-31
No files matched your search
@@ -11,6 +11,7 @@ import (
|
||||
"git.stormux.org/storm/cthulhu/internal/platform/session"
|
||||
"os"
|
||||
"os/exec"
|
||||
"strings"
|
||||
"time"
|
||||
)
|
||||
|
||||
@@ -62,3 +63,9 @@ func readClipboardMessage(ctx context.Context) (string, error) {
|
||||
}
|
||||
return result.Message, nil
|
||||
}
|
||||
|
||||
func writeClipboardText(ctx context.Context, value string) error {
|
||||
command := exec.CommandContext(ctx, "xclip", "-selection", "clipboard", "-in")
|
||||
command.Stdin = strings.NewReader(value)
|
||||
return command.Run()
|
||||
}
|
||||
Reference in new issue
Block a user