mykola2312
|
fa27bb575f
|
migrate all sql queries to postgres
|
2024-03-08 07:58:53 +02:00 |
|
mykola2312
|
406527d1ab
|
begin migrating to postgres
|
2024-03-08 07:01:12 +02:00 |
|
mykola2312
|
c588ca6136
|
make utility function to parse env
|
2024-03-08 05:24:39 +02:00 |
|
mykola2312
|
7f39503084
|
cargo fmt
|
2024-03-08 05:24:09 +02:00 |
|
mykola2312
|
d0fd88119c
|
implement download permission request system for chats
|
2024-03-04 00:59:24 +02:00 |
|
mykola2312
|
c00d1686a5
|
fix typos
|
2024-03-03 23:48:18 +02:00 |
|
mykola2312
|
594002a42e
|
implement approve and decline commands
|
2024-03-03 23:40:30 +02:00 |
|
mykola2312
|
7aa9010de1
|
implement macro to automatically parse integers from bot messages
|
2024-03-03 23:33:29 +02:00 |
|
mykola2312
|
a320919596
|
implement listrequests command
|
2024-03-03 22:33:05 +02:00 |
|
mykola2312
|
8e36fa1e08
|
begin implementing request listing
|
2024-03-03 22:26:58 +02:00 |
|
mykola2312
|
66cdc74a4b
|
request messages should never be nullable
|
2024-03-03 22:26:47 +02:00 |
|
mykola2312
|
5e133beb9b
|
every struct should be debuggable
|
2024-03-03 22:20:59 +02:00 |
|
mykola2312
|
2114912305
|
so bug was using AND instead of comma in UPDATE query. rookie mistake
|
2024-03-03 20:10:49 +02:00 |
|
mykola2312
|
4d2b01f961
|
fix bug when op wasn't setting admin access (when user was already created), add indecies on telegram ids in database
|
2024-03-03 20:02:50 +02:00 |
|
mykola2312
|
d71462589f
|
fix sql bug
|
2024-03-03 19:28:15 +02:00 |
|
mykola2312
|
f1b8f596d7
|
implement request command
|
2024-03-03 19:26:30 +02:00 |
|
mykola2312
|
8e649c043f
|
begin implementing permission requesting system
|
2024-03-03 19:05:29 +02:00 |
|
mykola2312
|
e692ebceb8
|
introduct macro to automatically reply with i18n message and return from command handler
|
2024-03-03 18:54:26 +02:00 |
|
mykola2312
|
da0f33df6b
|
add request_chat table for requesting access to download for chats
|
2024-03-03 18:05:16 +02:00 |
|
mykola2312
|
0a2bde0741
|
start cmd now works in chats as well
|
2024-03-03 18:02:03 +02:00 |
|
mykola2312
|
0825e5d96a
|
implement new chat memebers message handler to be able to know where bot have been added to register chat in database
|
2024-03-03 17:35:20 +02:00 |
|
mykola2312
|
fbb0a72039
|
implement my chat member update handler so bot will know when added to chat or channel and will add record to database
|
2024-03-03 16:58:17 +02:00 |
|
mykola2312
|
bb479f170b
|
implement macro for get and creating database objects
|
2024-03-03 00:44:38 +02:00 |
|
mykola2312
|
49d473f0cf
|
move all bot reply message texts to i18n yml file to avoid litering code with long strings
|
2024-03-02 20:16:18 +02:00 |
|
mykola2312
|
842a710928
|
implement command start (for private chats)
|
2024-03-02 19:04:02 +02:00 |
|
mykola2312
|
197429a422
|
impl Display for User so logging would be easy
|
2024-03-02 18:55:23 +02:00 |
|
mykola2312
|
8d50da9ead
|
revert idea with Arc<DbPool> because sqlx is already Arc internally
|
2024-03-02 17:57:32 +02:00 |
|
mykola2312
|
e3cf3fe655
|
implement user opping (elevating permissions to admin), use
Arc<SqlitePool> because dptree seems to clone deps everytime a dispatch
happens
|
2024-03-02 08:39:43 +02:00 |
|
mykola2312
|
c9eb89d4e8
|
implement op command to give myself admin permissions
|
2024-03-02 04:55:23 +02:00 |
|
mykola2312
|
2ae4708438
|
disable filter because it actually suppresses all errors, not just timeout errors
|
2024-03-02 04:55:11 +02:00 |
|
mykola2312
|
7fac64f8e4
|
introduce db pool type instead of hard-coded SqlitePool
|
2024-03-02 03:07:12 +02:00 |
|
mykola2312
|
1e6d671feb
|
rearrange file structure for bot commands
|
2024-03-02 02:53:54 +02:00 |
|
mykola2312
|
bb6687ac46
|
implement db structures for mapping
|
2024-03-02 02:22:31 +02:00 |
|
mykola2312
|
dd6f8a4f0e
|
remove cmd db test
|
2024-03-02 02:18:02 +02:00 |
|
mykola2312
|
b70bdde318
|
rearrange mod file structure
|
2024-03-02 02:10:11 +02:00 |
|
mykola2312
|
e8245413ab
|
begin messing around with sqlx
|
2024-03-02 01:50:30 +02:00 |
|
mykola2312
|
83b4488e8a
|
make logger output dbg! in debug build
|
2024-03-02 01:50:21 +02:00 |
|
mykola2312
|
da057a0040
|
add reminder to add initiated dialogs into table
|
2024-03-02 00:27:46 +02:00 |
|
mykola2312
|
626272eea6
|
add sqlx migration script
|
2024-03-01 02:02:09 +02:00 |
|
mykola2312
|
e53a03ca1c
|
update sql
|
2024-03-01 01:44:15 +02:00 |
|
mykola2312
|
75fc962c9a
|
make first migration to implement database
|
2024-03-01 01:17:48 +02:00 |
|
mykola2312
|
c393cec924
|
improve docker configs
|
2024-02-29 20:41:00 +02:00 |
|
mykola2312
|
754397604b
|
instead of file logging we're going to use stdout because bot will be run in container, therefore container output is a log
|
2024-02-29 20:20:06 +02:00 |
|
mykola2312
|
3ecbbd4ad2
|
use db and log paths as target/debug for debug run
|
2024-02-29 17:51:11 +02:00 |
|
mykola2312
|
80fcc9d5b6
|
introduce sqlx migrations
|
2024-02-29 16:23:15 +02:00 |
|
mykola2312
|
ee79869327
|
fix unused
|
2024-02-28 18:03:38 +02:00 |
|
mykola2312
|
9b0dc8fcd7
|
don't output ansi colors to log file
|
2024-02-27 01:40:27 +02:00 |
|
mykola2312
|
d5b5d156b7
|
make a layer filter to to prevent polling timeout errors from clogging logs
|
2024-02-27 01:13:43 +02:00 |
|
mykola2312
|
ed7c493b64
|
introduce logging to important functions
|
2024-02-26 22:46:08 +02:00 |
|
mykola2312
|
2424f4de77
|
make spawn function accept slice of &str instead of generics so joining into string for logging is easy
|
2024-02-26 22:12:47 +02:00 |
|