Linux: April 2007 Archives

It's often handy to send email from the command line using mail, however it isn't very obvious how to attach files to the resulting email. To do it, you just require uuencode. In both Debian and Red Hat based distributions, this will be in the sharutils package. To send attachment with the email run the following command:
(echo Email Body Text; uuencode ~/file1.zip file1.zip;) | mail -s "Email Subject" recipient@example.com
This will attach file1.zip to the email and send it to recipient@example.com.
Dave posted "stealing flash videos" in Windows, so I decided how simple it would be to do the same in Linux. A quick search found a bash script for doing exactly what I want. It also had the added bonus of converting it into an Mpeg video. The only requirements are bash, wget and ffmpeg. An application to play the mpeg might also be handy. The version of the script that I'm using is:
#!bin/bash # by Crouse - Program name ytr = YouTube.com Ripper clear; baseurl="http://youtube.com/get_video.php?"; mkdir -p ~/YouTube ; mkdir -p ~/YouTube/tmp ; cd ~/YouTube/tmp ; echo " "; read -p "What is the youtube.com url you want to rip ? " urltorip ; read -p "What would you like to name the video (no spaces in the name) ? " nameofvideo ; wget ${urltorip} -O urlsource.txt ; fullurl=${baseurl}`grep player2.swf urlsource.txt | cut -d? -f2 | cut -d\" -f1` ; rm * ; wget "${fullurl}" -O temp.flv ; ffmpeg -i temp.flv -ab 56 -ar 22050 -b 500 -s 320x240 ${nameofvideo}.mpg ; mv ${nameofvideo}.mpg ../ ; rm -Rf ~/YouTube/tmp ; exit
It looks like instead of getting easier for Linux to support hardware, there are more obstacles being thrown in the way. I came across two stories today which do not bode well for people wanting to use Linux on commodity hardware. First of all, seemingly Phoenix are now creating a crippled BIOS which will only support Windows Vista. My own view on this is that the BIOS should only be responsible for getting the PC ready for whatever Operating System the user chooses. A four year old article mentioned in the post seems to suggest that Microsoft are "embracing" Phoenix. If this is true, is it not the same anti-competitive behaviour that Microsoft have already gotten in trouble for? I know there is LinuxBios, but I haven't been brave enough to try it yet, so I can't comment on how good it is. AMD also don't seem to be getting it. MythTv and Beryl are two popular projects. Yet if you want to use accelerated 3D on ATI cards with either of the these projects, you are out of luck. AMD are a hardware company, they shouldn't give a toss about the drivers as long as they work. I know the 3D graphics market is highly competitive, and there is lots of proprietry tricks used in the drivers to get the last ounce of perforance. I would still rather if they would give the specs to someone like Dave Airlie and let him do nice open source drivers without NDAs hanging over him. I don't care if I loose a couple of frames per second. I'd rather have decent drivers. How many more hardware makers are shooting themselves by placing such obstacles to using Linux? Hopefully with the likes of Dell commiting to use Linux friendly hardware, AMD and Phoenix might begin to see sense.
Novell have bought out some parodies of the Apple "Get A Mac" campaign which feature Linux as a woman. One of the comments underneath is priceless:
Of course linux is a woman. It is generally stable, but ever so complicated, some would say impossible to ever really figure out. It requires a fair amount of attention and learning when starting out, as well as continued attention to keep up, as standards, layout and deployments change..
Thanks for this gem Tracker1 :)

About this Archive

This page is a archive of entries in the Linux category from April 2007.

Linux: March 2007 is the previous archive.

Linux: May 2007 is the next archive.

Find recent content on the main index or look in the archives to find all content.

Powered by Movable Type 4.01