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

Re-organized code and a lot of other stuff. #342

Merged
merged 25 commits into from
May 22, 2012
Merged

Conversation

FiloSottile
Copy link
Collaborator

Here is my recent work on youtube-dl. I've been really bold, but I tried to keep it elegant, in line with the philosophy of this project and tested.
Let's enumerate the changes:

  • [ The code should be broken out in smaller pieces #193 ] I've split the code in a python package, that is a bunch of files inside the youtube_dl directory. The package gets compiled by make compile into an executable zipfile. The zipfile is prepended with a shebang so that it remains executable on Linux.
    • This is a really stable and portable way to distribute the code: it is a single file; it behaves exactly as a script (supported on Python >= 2.6); the tracebacks are readable; it is compatible with all the platforms I was able to test on.
    • Please read that StackOverflow discussion and the relevant Python bug as a reference.
  • [ Provide an official exe for windows #153 ] I've written build_exe.py and wine-py2exe.sh that creates a Windows EXE automatically using WINE that is able to update itself.
    • When executed, wine-py2exe.sh creates a WINEPREFIX in wine-py2exe/, installs Python and py2exe inside it and the creates the exe using the setup.py passed as argument (build_exe.py).
    • That required a lot of hacks: the WINE support is achieved patching the PE headers of the template executables of py2exe; the -U writes a bat file and executes it before dying.
  • I dropped Python 2.5 support. Because:
  • [ Add the option to return only the info_dict #296 ] Moved increment_downloads and process_info calls from IEs to FD.download; a small step towards importability (about import #217)

That pull request includes the following branches, so refer to them for what the changes are:

This is a fast-forward ready merge from the current upstream.

FiloSottile and others added 25 commits March 18, 2012 22:15
…oad (#296) (follows current doclines); a small step towards importability #217
…HTML; fixed a bug in the use of _unescapeHTML (missing _, from d6a9615)
let's elaborate the decision: Python 2.5 is a 6 years old release
and "under the current release policy, no security issues in Python
2.5 will be fixed anymore" (!!); also, it doesn't support the new
zipfile distribution format.
and stitle is created in process_info() and is cross-filesystem sanitized by sanitize_filename();
closes #164
phihag added a commit that referenced this pull request May 22, 2012
Re-organized code and a lot of other stuff.
@phihag phihag merged commit 1b91a2e into ytdl-org:master May 22, 2012
@phihag
Copy link
Contributor

phihag commented May 22, 2012

These changes are too good to be left out. Merged all of them. I might change some details though before releasing a new version.

joedborg referenced this pull request in joedborg/youtube-dl Nov 17, 2020
[pull] master from ytdl-org:master
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

Successfully merging this pull request may close these issues.

youtube-dl: does not work with bit.ly
6 participants