Only allow /help in private
This commit is contained in:
parent
f592d7a8da
commit
03f23fa514
35
konata.sh
35
konata.sh
@ -79,23 +79,28 @@ debug(){
|
|||||||
|
|
||||||
# Public commands
|
# Public commands
|
||||||
help(){
|
help(){
|
||||||
sendmsg "Hiya! I'm <a href=\"https://t.me/ghnou\">ghnou</a>'s personal bot, Konata.
|
if [ $(jq -r '.message.chat.type' <<< $input) == "private" ]
|
||||||
|
then
|
||||||
|
sendmsg "Hiya! I'm <a href=\"https://t.me/ghnou\">ghnou</a>'s personal bot, Konata.
|
||||||
|
|
||||||
<b>Currently I have the following features:</b>
|
<b>Currently I have the following features:</b>
|
||||||
- /help - Show this help message.
|
- /help - Show this help message.
|
||||||
- /alive - Check whether I'm running.
|
- /alive - Check whether I'm running.
|
||||||
- /cv [country] - Check COVID-19 stats.
|
- /cv [country] - Check COVID-19 stats.
|
||||||
- /id - Get the current chat's ID.
|
- /id - Get the current chat's ID.
|
||||||
- /ud [term] - Get a definition from Urban Dictionary.
|
- /ud [term] - Get a definition from Urban Dictionary.
|
||||||
- /konata - Get one of my selfies :3
|
- /konata - Get one of my selfies :3
|
||||||
- /konachan [query] - Get a picture from Konachan.
|
- /konachan [query] - Get a picture from Konachan.
|
||||||
- /4c [board] - Get a random image from 4chan.
|
- /4c [board] - Get a random image from 4chan.
|
||||||
- /lfy [query] - Let me look that up for you...
|
- /lfy [query] - Let me look that up for you...
|
||||||
- /ip [address] - Get information for an IP address.
|
- /ip [address] - Get information for an IP address.
|
||||||
- /wttr [city] - Get the weather for a city.
|
- /wttr [city] - Get the weather for a city.
|
||||||
- /repo - Get my source code.
|
- /repo - Get my source code.
|
||||||
|
|
||||||
And a lot more to come!"
|
And a lot more to come!"
|
||||||
|
else
|
||||||
|
sendmsg "Please ask me in <a href=\"https://t.me/$bot\">private</a>!"
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
alive(){
|
alive(){
|
||||||
|
Loading…
x
Reference in New Issue
Block a user