GitHub Mirror of youtube-upload
Python Shell
Pull request Compare This branch is 1 commit ahead, 1 commit behind Miserlou:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
bin
examples
youtube_upload
CHANGELOG
README
setup.py

README

= Introduction =

_Youtube-upload_ is a command-line script that uploads videos to Youtube. If a video does not comply with Youtube limitations (<2Gb and <15') you must split it before using ffmpeg or any other tool. _Youtube-upload_ should work on any platform (GNU/Linux, BSD, OS X, Windows, ...) that runs Python.

= Dependencies =

  * [http://www.python.org python] (>= 2.6)
  * [http://code.google.com/p/gdata-python-client python-gdata] (>= 1.2.4)

= Download & Install =

  * [http://code.google.com/p/youtube-upload/downloads/list Stable release]:

{{{
$ wget http://youtube-upload.googlecode.com/files/youtube-upload-VERSION.tgz
$ tar xvzf youtube-upload-VERSION.tgz
$ cd youtube-upload-VERSION
$ sudo python setup.py install
}}}

  * [http://code.google.com/p/youtube-upload/source/checkout From repository]:

{{{
$ svn checkout http://youtube-upload.googlecode.com/svn/trunk/ youtube-upload
$ cd youtube-upload
$ sudo python setup.py install
}}}

  * If you don't want (or you can't) install software on the computer, run it directly from sources:

{{{
$ cd youtube-upload-VERSION
$ python youtube_upload/youtube_upload.py ...
}}}


= Usage examples =

* Upload a video:

{{{
$ youtube-upload --email=myemail@gmail.com --password=mypassword 
                 --title="A.S. Mutter" --description="A.S. Mutter plays Beethoven" 
                 --category=Music --keywords="mutter, beethoven" anne_sophie_mutter.flv
www.youtube.com/watch?v=pxzZ-fYjeYs
}}}

* Upload a splited video:

{{{
$ youtube-upload [OPTIONS] --title="TITLE" video.part1.avi video.part2.avi
www.youtube.com/watch?v=pxzZ-fYjeYs # title: TITLE [1/2]
www.youtube.com/watch?v=pxzZ-fYsdff # title: TITLE [2/2]
}}}

* Get available categories:

{{{
$ youtube-upload -c
Tech Education Animals People Travel Entertainment Howto Sports Autos Music News Games Nonprofit Comedy Film
}}}

* Split a video with _ffmpeg_

Youtube currently limits videos to <2Gb and <15' for almost all users. You can use the Bash example script to split it before uploading:

{{{
$ bash examples/split_video_for_youtube.sh video.avi
video.part1.avi
video.part2.avi
video.part3.avi
}}}

* Upload videos with _curl_

The script uses pycurl by default (when available) to upload the video, but if you need to tweak the upload parameters take a look at the Bash script included with the sources ([http://code.google.com/p/youtube-upload/source/browse/trunk/examples/upload_with_curl.sh examples/upload_with_curl.sh]). This command, for example, would upload _somevideo.flv_ with a limit rate of 100KBytes:

{{{
$ youtube-upload --get-upload-form-info [OPTIONS] | bash examples/upload_with_curl.sh --limit-rate 100k
}}}

= Feedback =

Use the [http://code.google.com/p/youtube-upload/issues/ issues tracker] to report bugs or suggest improvements. If your problem relates to splitting videos with ffmpeg you may better refer to specialized forums or mailing lists.