From 85accf176e3a00f966bd3393f213aa1684106ed3 Mon Sep 17 00:00:00 2001 From: Michael De Roover Date: Sun, 11 Apr 2021 20:48:30 +0200 Subject: [PATCH] Improve tag feature --- konata.sh | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/konata.sh b/konata.sh index 6ff7ee9..e529c95 100755 --- a/konata.sh +++ b/konata.sh @@ -279,7 +279,16 @@ anyone(){ # Miscellaneous tag(){ sendmsg "Please stand by, he'll get to your message soon™️..." - sendlog "You've been tagged: $msg" + chid=$(jq -r '.message.chat.id' <<< $input | sed 's/-100//') + msgid=$(jq -r '.message.message_id' <<< $input) + uname=$(jq -r '.message.from.username' <<< $input) + uid=$(jq -r '.message.from.id' <<< $input) + text=$(jq -r '.message.text' <<< $input) + sendlog "*You've been tagged.* + *User:* [$name](tg://user?id=$uid) + *Link:* [here](https://t.me/c/$chid/$msgid) + *Message contents:* + $(escape "()" "$text")" } hiya(){ sendmsg "Hiya! :3"