mirror of
https://github.com/thegeneralist01/social-media-video-downloader-bot
synced 2026-01-11 15:40:30 +01:00
initial commit
This commit is contained in:
commit
739ddf8cbe
4 changed files with 2233 additions and 0 deletions
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
|
|
@ -0,0 +1,2 @@
|
||||||
|
/target
|
||||||
|
.env
|
||||||
2204
Cargo.lock
generated
Normal file
2204
Cargo.lock
generated
Normal file
File diff suppressed because it is too large
Load diff
12
Cargo.toml
Normal file
12
Cargo.toml
Normal file
|
|
@ -0,0 +1,12 @@
|
||||||
|
[package]
|
||||||
|
name = "social-media-video-downloader-bot"
|
||||||
|
version = "0.1.0"
|
||||||
|
edition = "2024"
|
||||||
|
|
||||||
|
[dependencies]
|
||||||
|
dotenv = "0.15.0"
|
||||||
|
teloxide = { version = "0.14.1", features = ["macros"] }
|
||||||
|
log = "0.4"
|
||||||
|
pretty_env_logger = "0.5"
|
||||||
|
tokio = { version = "1.8", features = ["rt-multi-thread", "macros"] }
|
||||||
|
openssl = { version = "0.10.35", features = ["vendored"] }
|
||||||
15
src/main.rs
Normal file
15
src/main.rs
Normal file
|
|
@ -0,0 +1,15 @@
|
||||||
|
use teloxide::prelude::*;
|
||||||
|
|
||||||
|
#[tokio::main]
|
||||||
|
async fn main() {
|
||||||
|
dotenv::dotenv().ok();
|
||||||
|
pretty_env_logger::init();
|
||||||
|
log::info!("Starting the bot");
|
||||||
|
|
||||||
|
let bot = Bot::from_env();
|
||||||
|
|
||||||
|
teloxide::repl(bot, |bot: Bot, msg: Message| async move {
|
||||||
|
bot.send_message(msg.chat.id, "hi").await.ok();
|
||||||
|
Ok(())
|
||||||
|
}).await;
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue