tg-dumb-bot

module
v0.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 11, 2023 License: MIT

README

TG DUMB BOT

pull_request_closed docker_pull issue license last_commit

This is a funny tg dumb bot.

Features

Warning
All code only for reference.
Check CAREFULLY before deployment.

♻️ Using weibo command can feed you the TOP10 RUBBISH on Weibo platform RIGHT NOW!

🎲 The choice command gives you a random choice between serveral space-sperated options.

🤡 This bot will also randomly reply "Surprise Sunshine Boy!" to a new arrived message in the group with a probability of 0.15.

Propose your function now with a single PR.

Usage

Build from source
Build with Go

Dependencies

go get github.com/go-telegram-bot-api/telegram-bot-api/v5
go get github.com/joho/godotenv
go get github.com/gocolly/colly/v2

Paste your token into .env like:

TELEGRAM_APITOKEN=123456:ABCDEFGHIJKLMN
DEBUG=1

Then

rm -rf bin
go mod tidy
go build -o bin/ ./app/main
nohup ./bin/main > ./test.log 2>&1 &
Build with Docker
docker build . -t test
# run on detach
docker run -d -v /etc/localtime:/etc/localtime:ro -e token="123456:ABCDEFGHIJKLMN" test
# run in foreground
docker run -it -v /etc/localtime:/etc/localtime:ro -e token="123456:ABCDEFGHIJKLMN" test
Use DockerHub Image
docker pull hackroid/tg-dumb-bot:latest
docker run --name bot-one -d -v /etc/localtime:/etc/localtime:ro -e token="123456:ABCDEFGHIJKLMN" hackroid/tg-dumb-bot:latest

Directories

Path Synopsis
app
pkg

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL