Skip to content

Latest commit

 

History

History
37 lines (24 loc) · 906 Bytes

README.md

File metadata and controls

37 lines (24 loc) · 906 Bytes

Telegram bot for tracking your dog activity in a very simple way

Storage - sqlite

Fast start

  1. Use golang 1.22
  2. Create a new bot with BotFather
  3. Save token as a temporary env for start. Copy paste next command:
read -s TELEGRAM_TOKEN
  1. Copy the bot's token into the input field of the previous command once and press enter (pasted token will be invisible)

  2. install sqlc for generating code from sql. For macos brew users just copy paste next command:

brew install sqlc
  1. Run migrations and start the bot with air help. Just copy paste next command:
TELEGRAM_TOKEN=$TELEGRAM_TOKEN go run github.com/cosmtrek/air@latest
  1. Go to your bot and type /start

  2. check your base with sqlite3

sqlite3 -readonly database.sqlite3
  1. deploy it whereever you want