egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

youtube to mp3 download

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests
View previous topic :: View next topic  
Author Message
mabrook
Halfop


Joined: 14 Jun 2021
Posts: 60

PostPosted: Thu Aug 19, 2021 5:59 pm    Post subject: youtube to mp3 download Reply with quote

hello all..

just posting the idea that i got it from other irc networks. since a lot of coders now doing YouTube script to get the info/data/etc...

how about we get the YouTube info/music/audio/video and convert to mp3 and downloaded it to specific path/dir. in specific user shell .

let's say [user shell public_html)


http://x.x.x.x/~user



example:

[user] !yt youtube-link
[bot] Converting to mp3: http://x.x.x.x/youtube-link.mp3

after awhile (60seconds or 90seconds)

[bot] Download here: http://x.x.x.x/youtube-link.mp3



i hope anyone get the idea.. Razz Razz Razz Razz
Back to top
View user's profile Send private message
CrazyCat
Revered One


Joined: 13 Jan 2002
Posts: 1032
Location: France

PostPosted: Fri Aug 20, 2021 2:22 am    Post subject: Reply with quote

Not a new idea. Have a look to http://forum.egghelp.org/viewtopic.php?t=19601 or search for "youtube-dl" in the forum
_________________
https://www.eggdrop.fr - French IRC network
Offer me a coffee - Do not ask me help in PM, we are a community.
Back to top
View user's profile Send private message Visit poster's website
mabrook
Halfop


Joined: 14 Jun 2021
Posts: 60

PostPosted: Fri Aug 20, 2021 4:50 am    Post subject: Reply with quote

Code:
Not a new idea. Have a look to http://forum.egghelp.org/viewtopic.php?t=19601 or search for "youtube-dl" in the forum




although the idea is there.. but it is different way ..



while from here is a different way also,, let's say [user shell public_html)

http://x.x.x.x/~user

Example:
[user] !yt youtube-link
[bot] Converting to mp3: youtube-link.mp3 , please wait... (youtube link converting )

after awhile (60seconds or 90seconds)

[bot] Download here: http://x.x.x.x/youtube-link.mp3 <-- see this one, it will appear in the channel, and this link is clickable to download


i hope you see a difference ..


Razz Razz Razz Razz Razz Razz Razz Razz
Back to top
View user's profile Send private message
CrazyCat
Revered One


Joined: 13 Jan 2002
Posts: 1032
Location: France

PostPosted: Fri Aug 20, 2021 5:03 am    Post subject: Reply with quote

I don't see any difference, appart that the message is different and you want to put the mp3 file on a public webspace.

I'll see if I can find 15' to do a little script
_________________
https://www.eggdrop.fr - French IRC network
Offer me a coffee - Do not ask me help in PM, we are a community.
Back to top
View user's profile Send private message Visit poster's website
mabrook
Halfop


Joined: 14 Jun 2021
Posts: 60

PostPosted: Fri Aug 20, 2021 5:15 am    Post subject: Reply with quote

sorry i forgot to mention..


once the file will be downloaded and be put in here;

http://x.x.x.x/youtube-link.mp3


there's a limited time only from this file to be stored in public..

let's say , after 1hour or 2hours it will be deleted automatically..


*** The purpose is to convert the youtube-link to mp3 and store the file in public_html of the user and it will be deleted after specific time.

That's it..
Back to top
View user's profile Send private message
CrazyCat
Revered One


Joined: 13 Jan 2002
Posts: 1032
Location: France

PostPosted: Fri Aug 20, 2021 5:28 am    Post subject: Reply with quote

deleting a file after a delay is quite simple.
You can do it using bash:
Code:
find /your/public/path/ -iname '*.mp3' -mmin 120 -exec rm -f {} \;


You can also do it with a tcl script:
Code:
set mp3path "/your/public/path/"
bind cron - "* * * * *" delmp3
proc delmp3 {min hour day month dow} {
   set tmpfiles [glob -directory $::mp3path *.mp3]
   foreach mp3 $tmpfiles {
      if {[file mtime $mp3]<[expr {[clock seconds] - (120*60)}]} {
         file delete -force $mp3
      }
   }
}

_________________
https://www.eggdrop.fr - French IRC network
Offer me a coffee - Do not ask me help in PM, we are a community.
Back to top
View user's profile Send private message Visit poster's website
mabrook
Halfop


Joined: 14 Jun 2021
Posts: 60

PostPosted: Fri Aug 20, 2021 5:37 am    Post subject: Reply with quote

that's a good one... i hope i know how to do it.. Razz



can you make a simple script for that with


youtube to mp3 and the integrate the specific time to delete the file..


i really don't have any idea or know how to begin with..

Razz Razz Razz Razz
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber