From f951956db5430323140ec1835e0ea68e52fe72d7 Mon Sep 17 00:00:00 2001 From: Leonardo Domingues Date: Wed, 15 Dec 2021 10:44:27 -0300 Subject: [PATCH] AHK and Autoit implemented --- api/autohotkey/cli.go | 24 ++++++++++++++++++++++++ api/autoit/cli.go | 24 ++++++++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 api/autohotkey/cli.go create mode 100644 api/autoit/cli.go diff --git a/api/autohotkey/cli.go b/api/autohotkey/cli.go new file mode 100644 index 0000000..2f30ddd --- /dev/null +++ b/api/autohotkey/cli.go @@ -0,0 +1,24 @@ +package autohotkey + +import ( + "go.digitalcircle.com.br/open/replaycli-go/api" +) + +type Cli struct { + *api.ApiCli +} + +func NewCli() *Cli { + ret := &Cli{ApiCli: api.NewApiCli()} + return ret +} + +func (c *Cli) Test() (ret string, err error) { + err = c.HttpCli().JsonPost("/ipc/ahk/test", nil, &ret) + return ret, err +} + +func (c *Cli) Do(data string) (ret string, err error) { + err = c.HttpCli().JsonPost("/ipc/ahk/do", data, &ret) + return ret, err +} diff --git a/api/autoit/cli.go b/api/autoit/cli.go new file mode 100644 index 0000000..cb2c2db --- /dev/null +++ b/api/autoit/cli.go @@ -0,0 +1,24 @@ +package autoit + +import ( + "go.digitalcircle.com.br/open/replaycli-go/api" +) + +type Cli struct { + *api.ApiCli +} + +func NewCli() *Cli { + ret := &Cli{ApiCli: api.NewApiCli()} + return ret +} + +func (c *Cli) Test() (ret string, err error) { + err = c.HttpCli().JsonPost("/ipc/autoit/test", nil, &ret) + return ret, err +} + +func (c *Cli) Do(data string) (ret string, err error) { + err = c.HttpCli().JsonPost("/ipc/autoit/do", data, &ret) + return ret, err +}