From c875585c4b1fd023f751703637b019995892d944 Mon Sep 17 00:00:00 2001 From: Steve Date: Tue, 17 Jan 2023 23:53:18 -0500 Subject: [PATCH] more text, make podman --- Makefile | 5 ++++- main.go | 7 +++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index a34ec20..b1b0c82 100644 --- a/Makefile +++ b/Makefile @@ -10,9 +10,12 @@ endif $(PROG): $(GOFILES) go build -ldflags "-X main.GitCommit=$(GIT_COMMIT) -X main.GitTag=$(GIT_TAG)" -clean: +clean: rm -f simpbot +podman: $(GOFILES) + podman build -t git.saintnet.tech/stryan/$(PROG) . + install: $(SIMPBOT) install -d $(DESTDIR)$(PREFIX)/bin install -m 755 $(PROG) $(DESTDIR)$(PREFIX)/bin diff --git a/main.go b/main.go index 03b0766..791e79b 100644 --- a/main.go +++ b/main.go @@ -158,11 +158,18 @@ func main() { client.SendText(evt.RoomID, "Need a member to subscribe to") } vt := body_s[2] + var subbed bool for _, v := range vtubers { if strings.ToUpper(v.Name) == strings.ToUpper(vt) { v.Subs[evt.Sender] = true + subbed = true } } + if subbed { + client.SendText(evt.RoomID, "subbed") + } else { + client.SendText(evt.RoomID, "could not identify talent to subscribe to") + } case "help": client.SendText(evt.RoomID, "Supported commands: info,version,stats,reload,subscribe")