Skip to content
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

Invalid output dir #2

Open
elmobotix opened this issue Feb 15, 2021 · 18 comments
Open

Invalid output dir #2

elmobotix opened this issue Feb 15, 2021 · 18 comments

Comments

@elmobotix
Copy link

I get:

NotADirectoryError: [WinError 267] The directory name is invalid: 'C:\Users\elmo/Videos/SafariBooks/Python for Beginners: Learn Python from Scratch'

@zdr1976
Copy link
Owner

zdr1976 commented Feb 16, 2021

Hi,

I'm no more using this scrip as the youtube-dl can do it by its own. It can also download videos from another popular site like udemy an so. Please have a look.

@elmobotix
Copy link
Author

elmobotix commented Feb 16, 2021

Hi, Ah OK. Can YouTube-dl manage full batch downloads so I can get a full course rather than single videos from Oreilly?

@zdr1976
Copy link
Owner

zdr1976 commented Feb 16, 2021

Yes this tool can download whole video course.

@elmobotix
Copy link
Author

elmobotix commented Feb 16, 2021 via email

@zdr1976
Copy link
Owner

zdr1976 commented Feb 16, 2021

So here you are example how to download via youtube-dl

youtube-dl -u your@account.com -o '%(playlist_title)s/%(playlist_index)s-%(title)s.%(ext)s' -f 'bestvideo[height<=720]+bestaudio/best[height<=720]/worst' https://learning.oreilly.com/videos/node-js-api-masterclass/9781800569638/

You can adjust quality and output as you need. Check manual pages for more options. This is one i use.

@elmobotix
Copy link
Author

elmobotix commented Feb 16, 2021 via email

@elmobotix
Copy link
Author

elmobotix commented Feb 16, 2021 via email

@elmobotix
Copy link
Author

elmobotix commented Feb 16, 2021 via email

@zdr1976
Copy link
Owner

zdr1976 commented Feb 16, 2021

-u is user name on oreilly.com it's email address as your account.

@elmobotix
Copy link
Author

elmobotix commented Feb 16, 2021 via email

@zdr1976
Copy link
Owner

zdr1976 commented Feb 16, 2021

Just follow the installation instructions here.

@elmobotix
Copy link
Author

elmobotix commented Feb 16, 2021 via email

@zdr1976
Copy link
Owner

zdr1976 commented Feb 16, 2021

In the example above i'm using -o '%(playlist_title)s/%(playlist_index)s-%(title)s.%(ext)s' to name the directory and files. So just modify it to your liking.

@elmobotix
Copy link
Author

elmobotix commented Feb 16, 2021 via email

@zdr1976
Copy link
Owner

zdr1976 commented Feb 16, 2021

You're welcome.

@elmobotix
Copy link
Author

elmobotix commented Feb 17, 2021

Hi again

Do you the books downloader too?

I use it but would like to know how I could tweak the .py to prompt for book ID as well as email addy and password.

Any ideas
Steve

@zdr1976
Copy link
Owner

zdr1976 commented Feb 17, 2021

You can tweak it as much as you want. For argument parsing you can use argparse python module.

@elmobotix
Copy link
Author

elmobotix commented Feb 17, 2021 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants