Search Members Help

» Welcome Guest
[ Log In :: Register ]

Mini-ITX Boards Sale, Fanless BareBones Mini-ITX, Bootable 1G DSL USBs, 533MHz Fanless PC <-- SALE $200 each!
Get The Official Damn Small Linux Book. DSL Market , Great VPS hosting provided by Tektonic
Pages: (5) </ [1] 2 3 4 5 >/

[ Track this topic :: Email this topic :: Print this topic ]

reply to topic new topic new poll
Topic: Script for downloading Youtube videos< Next Oldest | Next Newest >
curaga Offline





Group: Members
Posts: 2163
Joined: Feb. 2007
Posted: June 26 2007,16:13 QUOTE

Don't look at me like that, I know it isn't useful.
But I just read Advanced bash scripting guide and I had to try my skills on something.. So here's a very much enhanced version of the one from nixcraft.

I added some looks, clarity, comments, help switch, ability to get urls from nearly unlimited number of args...

After download they can be watched with Mplayer or flash player, and edited with mencoder..

Try and comment it


--------------
There's no such thing as life. Those mean little jocks invented it ;)
-
Windows is not a virus. A virus does something!
Back to top
Profile PM 
WDef Offline





Group: Members
Posts: 798
Joined: Sep. 2005
Posted: June 26 2007,19:36 QUOTE

Hey Curaga,

Not sure about this:

Code Sample
[[ $1 = http://* ]]


Try instead:

Code Sample
[ ${1%%://*} = http ]


to test if the beginning of the argument string is http://

EDIT: forget it, what you have works.  I wasn't looking at the double brackets.
Back to top
Profile PM 
u2musicmike Offline





Group: Members
Posts: 149
Joined: April 2006
Posted: June 30 2007,15:36 QUOTE

I couldn't get it working.  I think it bombs out on the mktemp part.  I tried another name for tmp and it got further along.  Then it looked like error 303 on the wget.  Oh well interesting script.
Back to top
Profile PM 
curaga Offline





Group: Members
Posts: 2163
Joined: Feb. 2007
Posted: July 01 2007,05:44 QUOTE

I didn't create it on DSL, so mktemp might be missing. Just replace it with a name..
Isn't error 303 just a redirection? I get something like that always, Youtube has 3 servers to balance traffic..


--------------
There's no such thing as life. Those mean little jocks invented it ;)
-
Windows is not a virus. A virus does something!
Back to top
Profile PM 
curaga Offline





Group: Members
Posts: 2163
Joined: Feb. 2007
Posted: July 01 2007,06:19 QUOTE

More detailed usage:

Go to the Youtube video page you wish to download. Like here's a video of DSL:
http://www.youtube.com/watch?v=prjQ7MwuCWI
Copy that url. Then open Aterm and start this script (youtubedl if you haven't renamed)
and when it asks for that url, paste it there..

Or call it as "youtubedl http://www.youtube.com/watch?v=prjQ7MwuCWI"


--------------
There's no such thing as life. Those mean little jocks invented it ;)
-
Windows is not a virus. A virus does something!
Back to top
Profile PM 
21 replies since June 26 2007,16:13 < Next Oldest | Next Newest >

[ Track this topic :: Email this topic :: Print this topic ]

Pages: (5) </ [1] 2 3 4 5 >/
reply to topic new topic new poll
Quick Reply: Script for downloading Youtube videos

Do you wish to enable your signature for this post?
Do you wish to enable emoticons for this post?
Track this topic
View All Emoticons
View iB Code