-
-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature request for silent downloads #8
Comments
Thanks @nkmathew for these great ideas. I am busy today, so I will try to make this possible ASAP. Stay tuned :) |
@nkmathew Updated version will be soon :) |
Published v1.0.9:
To download videos without logging (silent mode): from redvid import Downloader
reddit = Downloader()
# Due to silent mode, user quality query won't be visible so redvid
# automatically downloads maximum quality unless minimum is set
reddit.log = False
reddit.url = 'https://www.reddit.com/r/PublicFreakout/comments/ho5ml9/former_judges_michael_conahan_and_mark_ciavarella/'
reddit.download() To set a maximum size that is not allowed to be exceeded (like your 20 MB example): from redvid import Downloader
reddit = Downloader()
# Set max size to 20 MB
# Size is passed in BYTES
reddit.max_s = 20 * (1 << 20)
# The next video at max 1080p is 125 MB
reddit.url = 'https://www.reddit.com/r/PublicFreakout/comments/ho5ml9/former_judges_michael_conahan_and_mark_ciavarella/'
reddit.download() Now if the video exceeds 20 MB, nothing will be downloaded and function will return error number corresponding to size which equals 0. Hope you find redvid helpful all the time :) |
Hey Khaled,
Thanks for the making this. Do you think you could add an option for disabling the progress messages so we can clean logs? Like a silent flag in most command line applications
Also I have a use case where I'd like to only mirror a reddit video if it's not too big e.g if the video is over 20MB don't download it. Is this something that can be implemented?
The text was updated successfully, but these errors were encountered: