clive - extract videos from youtube, google video and dailymotion
Filename options:
-C STRING,
--filename-chars=STRING
set STRING (regexp) as accepted filename
(title) characters, e.g.
--filename-chars="A-Za-z0-9"
-F STRING,
--filename-format=STRING
use STRING for formatting video filenames, e.g.
--filename-format="%t.%e" accepted identifiers:
%t=title, %i=id, %h=host, %e=extension
--output-file=FILE write video file(s) to FILE
(overrides the above two options)
Re-encode options:
Use the -y switch with ffmpeg to overwrite existing output files
--encoder=STRING e.g. --encoder="/usr/bin/ffmpeg -y -i %i %o"
-m, --mpeg re-encode extracted video to mpeg
-a, --avi re-encode extracted video to avi
-f, --flv re-encode extracted video to flv
-E, --no-encode explicitly turn off re-encoding
Player options:
--player=STRING e.g. --player="/usr/bin/vlc %i"
-p, --play play video after extraction
-P FORMAT,
--play-format=FORMAT
play re-encoded video
-L, --no-play explicitly turn off play after extraction
Proxy options:
Proxy is on by default if the appropriate env. variable is defined
--proxy=PROXY set PROXY as proxy
--proxy-user=USER set USER as proxy username
--proxy-pass=PASS set PASS as proxy password
-R, --no-proxy explicitly turn off proxy
Youtube options:
--youtube-user=USER
set USER as youtube username
--youtube-pass=PASS
set PASS as youtube password
--youtube-status display youtube.com log-in info
--youtube-logout logout from youtube.com
-Y,
--no-youtube-login
explicitly turn off login to youtube.com
Extract a video from the specified URL. If none is specified,
clive reads standard input (stdin) for URLs. You can use pipes
with clive, for example:
# clive < urls.txt
# cat urls.txt | clive
For both FILE and stdin, separate each URL by a newline (LF),
e.g.:
url1
url2
url3
url4
url5
...
clive --encoder="/path/to/ffmpeg -y -b 128 -ab 128 -i %i %o" --mpeg URL
Re-encode extracted video to mpeg. Notice the use of
%i (input file) and %o (output file), both are required.
mencoder can be used in a similar fashion, e.g:
--encoder="/usr/bin/mencoder %i -ovc lavc -oac mp3lame -o %o"
clive --player="/path/to/player %i" --play URL
Play video after extraction. Unlike with --encoder, only
%i (input file) is required.
e.g.:
clive -p player="vlc --fullscreen %i" URL
use_newt = on/off
Enable/disable newt UI, enabled by default if newt is installed.
`--no-newt' disables it'.
user_agent = string
Use string as user-agent for HTTP connections, the same as `--agent'.
prefix = string
Save extracted videos to prefix, the same as `--prefix'.
http_proxy = string
Use string as HTTP proxy, instead of the one specified in env.
You can disable the use of HTTP proxy with `--no-proxy'.
proxy_user = string
Set PROXY authentication user name to string, the same
as `--proxy-user'.
proxy_pass = string
Set PROXY authentication password to string, the same
as `--proxy-pass'.
youtube_user = string
Set youtube.com user name to string, the same
as `--youtube-user'.
youtube_pass = string
Set youtube.com password to string, the same
as `--youtube-pass'.
NOTE: Both youtube_user and youtube_pass must be used in
order to log into youtube.com. If they are used,
clive checks the login status at startup and logs in
if required.
You can bypass the login procedure with
`--youtube-no-login' while the above two variables
are being used.
player = string
Set player to string, the same as `--player'.
Example:
player = vlc --fullscreen %%i
NOTE: %%i is not a typo, be sure to use %% in cliverc
encoder = string
Set encoder to string, the same as `--encoder'.
Example:
encoder = ffmpeg -y -b 1200 -ab 128 -i %%i %%o
NOTE: Use %% instead of % in cliverc
Be sure to use -y with ffmpeg, this tells
ffmpeg to overwrite the existing output file
without a prompt.
always_accept = on/off
Enable/disable extraction without prompting, the same
as `--accept'. `--no-accept' disables it.
always_play = on/off
Enable/disable playing extracted video, the same
as `--play'. `--no-play' disables it.
play_format = string
Set default play format as string, like `--play-format=FORMAT'.
`--no-play' and `--no-encode' disable it.
NOTE: Sets (and overrides) `--play' and `--FORMAT'
encode_format = string(s)
Re-encode videos to formats defined by the string,
like `--mpeg/avi/flv'. `--no-encode' disables it.
It is possible to pass more than one format, e.g.:
encode_format = mpeg,avi
always_skip = on/off
Enable/disable skipping already extracted videos, the
same as `--skip'. `--no-skip' disables it.
always_strip = on/off
Enable/disable stripping stdout messages, `--no-strip'
disables it. `--no-strip' disables it.
filename_chars = STRING
Set STRING as the accepted filename (title) characters
(default: A-Za-z0-9). The same as `--filename-chars'.
filename_format = STRING
Set STRING as the filename format (default: %t.%e).
The same as `--filename-format'.
NOTE: Use %% instead of %, e.g. %%t
NOTES:
(1) on/off equals to 0/1, true/false and yes/no
(2) Example cliverc:
[clive]
player = vlc --fullscreen %%i
encoder = /usr/bin/ffmpeg -y -b 1200 -ab 128 -i %%i %%o
http_proxy = http://proxy:80
youtube_user = myusername
youtube_pass = myuserpass
always_accept = yes
encode_format = mpeg
always_play = on
filename_chars = A-Za-z0-9 ,!?
filename_format = %%t (%%i) [%%h].%%e
YouTube: Login
This enables extraction of any videos that would otherwise
require logging in. To login, use `--youtube-user' and
`--youtube-pass'.
The log-in cookies are saved to file ~/.clivecookies. As long as
this file with the required cookies (LOGIN_INFO, is_adult)
exists, all of the youtube.com extractions are made as the
user that is logged in.
NOTES:
(1) clive sets the is_adult cookie by default meaning
that any material that has been flagged as 'mature
content' will be extracted without a confirmation.
(2) Log in is done over insecure HTTP connections,
anyone intercepting the HTTP traffic could steal the
login info.
(3) youtube.com sets a handful of other cookies, more or less
relevant to login. See the ~/.clivecookies file to view
them all.
(4) clive does not accept any cookies from any of the websites
by default. The only exception is made for youtube.com
when the user is logged or logging in.
(5) If privacy is a concern, avoid using this feature.
Google Video
Extracted videos are saved as AVI videos (.avi).
Dailymotion
Extracted videos are saved as flash videos (.flv)
NOTE: Embedded videos are not currently supported
NOTE: Login is not currently supported
Video filenames
The saved video filename is generated from a video page
<title> HTML tag. If that fails, a random string is
used instead. This is done slightly differently for Google
Video; the title is retrieved from a GVP file.
Or, checkout the current development code from the repository:
svn co svn://svn.gna.org/svn/clive/trunk clive
https://gna.org/bugs/?func=additem&group=clive
In the bug report, please include:
* Information about your system. For instance:
- what operating system and version
- what Python version
- anything else you think is relevant
* How to reproduce the bug
* If the bug was a crash, the exact text that was printed
out when the crash occurred
* Further information such as the back trace if possible
clive comes with NO WARRANTY, to the extent permitted by law. You may redistribute copies of clive under the terms of the GNU General Public License. For more information about these matters, see the files named COPYING.
Закладки на сайте Проследить за страницей |
Created 1996-2024 by Maxim Chirkov Добавить, Поддержать, Вебмастеру |