Commit Graph

52 Commits (392389b7df7b818f794b231f14dc396d4875fbad)

Author SHA1 Message Date
pukkandan 392389b7df
[cleanup] Misc 1 year ago
Simon Sawicki 77df20f14c
[update] Add option `--update-to`, including to nightly (#6220)
* By default, stable will only update to stable, and nightly to nightly

Authored by: Grub4K, bashonly, pukkandan

Co-authored-by: bashonly <88596187+bashonly@users.noreply.github.com>
1 year ago
Simon Sawicki 5be214abed
[update] Fix updater file removal on windows (#5970)
Reverts 2fb0f85868
Closes #5632
Authored by: Grub4K
1 year ago
pukkandan 2fb0f85868
[update] Workaround #5632 1 year ago
Robert Geislinger 7aaf4cd2a8
[cleanup] Misc
Closes #5471, Closes #5312

Authored by: pukkandan, Alienmaster
2 years ago
MrOctopus 17fc3dc48a
[build] Create armv7l and aarch64 releases (#5449)
Closes #5436
Authored by: MrOctopus, pukkandan
2 years ago
pukkandan ff48fc04d0
[update] Use error code 100 for update errors
This error code was previously used for
"Exiting to finish update", but is no longer used

Closes #5198
2 years ago
pukkandan da4db748fa
[utils] Add `deprecation_warning`
See https://github.com/yt-dlp/yt-dlp/pull/2173#issuecomment-1097021515
2 years ago
pukkandan b5e7a2e69d
Add version to infojson 2 years ago
pukkandan 6440c45ff3
[update] Copy bitmask from old binary
Improves a6125983ab

Authored by: Lesmiscore
2 years ago
pukkandan a6125983ab
[update] Set executable bit-mask
Closes #4621
2 years ago
pukkandan 70b2340909
[build, devscripts] Add devscript to set a build variant
Closes #4471
2 years ago
pukkandan 24093d52a7
[update] Prepare to remove Python 3.6 support 2 years ago
pukkandan a63b35a60c
[update] Do not check `_update_spec` when up to date 2 years ago
pukkandan b1f94422cc
[update] Ability to set a maximum version for specific variants 2 years ago
Stefan Lobbenmeier 63da2d0911
Fix bug in 6d916fe709 (#4219)
Update only to legacy version on old MacOS

Authored by: StefanLobbenmeier
2 years ago
crazymoose77756 962ffcf89c
[cleanup] Fix some typos (#4194)
Authored by: crazymoose77756
2 years ago
pukkandan e4afcfde08
[build] Add Linux standalone builds 2 years ago
pukkandan 8372be7469
[update] Self-restart after update 2 years ago
pukkandan 57e0f077a6
[update] Expose more functionality to API 2 years ago
pukkandan 233ad894d3
[update] Use `.git` folder to distinguish `source`/`unknown`
This is not perfect, but is good enough for how we use this information

Closes #3994
2 years ago
pukkandan b5899f4f19
[build, cleanup] Refactor
Closes #3835, #3837
2 years ago
pukkandan c487cf0010
[cleanup] Misc 2 years ago
pukkandan 0b9c08b47b
[utils] Improve performance using `functools.cache`
Closes #3786
2 years ago
pukkandan 0f06bcd759
[cleanup] Minor fixes (See desc)
* [youtube] Fix `--youtube-skip-dash-manifest`
* [build] Use `$()` in `Makefile`. Closes #3684
* Fix bug in 385ffb467b
* Fix bug in 43d7f5a5d0
* [cleanup] Remove unnecessary `utf-8` from `str.encode`/`bytes.decode`
* [utils] LazyList: Expose unnecessarily "protected" attributes
and other minor cleanup
2 years ago
pukkandan f82711587c
[cleanup] Sort imports
Using https://github.com/PyCQA/isort

    isort -m VERTICAL_HANGING_INDENT --py 36 -l 80 --rr -n --tc .
2 years ago
pukkandan 86e5f3ed2e
[cleanup] Upgrade syntax
Using https://github.com/asottile/pyupgrade

1. `__future__` imports and `coding: utf-8` were removed
2. Files were rewritten with `pyupgrade --py36-plus --keep-percent-format`
3. f-strings were cherry-picked from `pyupgrade --py36-plus`

Extractors are left untouched (except removing header) to avoid unnecessary merge conflicts
2 years ago
felix cfb0511d82
[cleanup] Remove unused code paths (#2173)
Notes:

* `_windows_write_string`: Fixed in 3.6
  * https://bugs.python.org/issue1602
  * PEP: https://www.python.org/dev/peps/pep-0528

* Windows UTF-8 fix: Fixed in 3.3
  * https://bugs.python.org/issue13216

* `__loader__`: is always present in 3.3+
  * https://bugs.python.org/issue14646

* `workaround_optparse_bug9161`: Fixed in 2.7
  * https://bugs.python.org/issue9161

Authored by: fstirlitz
2 years ago
pukkandan 455a15e2dc
[cleanup,docs] Minor fixes
Closes #2541, #2484
2 years ago
pukkandan b69fd25c25
[cleanup] Misc cleanup
Closes #1942 #1976 #2020 #2058 #1984
2 years ago
pukkandan 91f071af60
Release 2021.12.01 2 years ago
pukkandan ee8dd27a73
[cleanup] Add deprecation warnings 2 years ago
pukkandan 75b725a7cc
[build] Use `workflow_dispatch` for release 2 years ago
pukkandan 733d8e8f99
[build] Refactor `pyinst.py` and misc cleanup
Closes #1361
3 years ago
pukkandan 386cdfdb5b
[build] Release windows exe built with py2exe
Closes: #855
Related: #661, #705, #890, #1024, #1160
3 years ago
Ricardo 0e5927eebf
[build] Build standalone MacOS packages (#1221)
Closes #1075 
Authored by: smplayer-dev
3 years ago
pukkandan d3c93ec2b7
Don't create console for subprocesses on Windows (#1261)
Closes #1251
3 years ago
pukkandan e6faf2be36
[update] Clean up error reporting
Closes #1224
3 years ago
pukkandan 5d535b4a55
[build] Allow building with py2exe (and misc fixes)
py2exe config is copied from youtube-dl
Closes #1160
3 years ago
pukkandan 28234287f1 [update] Check for new version even if not updateable 3 years ago
pukkandan 4c88ff87fc
[build] Improve release process (#880)
* Automate more of the release process by animelover1984, pukkandan - closes #823
* Fix sha256 by nihil-admirari - closes #385
* Bring back brew taps by nao20010128nao #865
* Provide `--onedir` zip for windows by pukkandan - Closes #1024, #661, #705 and #890

Authored by: pukkandan, animelover1984, nihil-admirari, nao20010128nao
3 years ago
pukkandan 0181adefc6
[build] Build Windows x86 version with py3.7
and remove redundant tests
Closes #390

:ci skip

Co-authored by: pukkandan, shirt-dev
3 years ago
pukkandan b5c5d84f60
Revert "[build] Build Windows x86 version with py3.8"
This reverts commit aa75e51f99.

See #390

This is being reverted instead of modified due to #388
3 years ago
pukkandan aa75e51f99
[build] Build Windows x86 version with py3.8
and remove redundant tests
:ci skip

Ao-authored by: pukkandan, shirt-dev
3 years ago
Nil Admirari beb982bead
[build,update] Add GNU-style SHA512 and prepare updater for simlar SHA256 (#383)
Authored by: nihil-admirari <50202386+nihil-admirari@users.noreply.github.com>

Related: #385
3 years ago
pukkandan 4040428efc
[update] Block further update for unsupported systems 3 years ago
pukkandan b25522ba52
[update] Replace self without launching a subprocess in windows
Closes: #335, https://github.com/ytdl-org/youtube-dl/issues/28488, https://github.com/ytdl-org/youtube-dl/issues/5810, https://github.com/ytdl-org/youtube-dl/issues/5994

In windows, a running executable cannot be replaced. So, the old updater worked by launching a batch script and then exiting, so that the batch script can replace the executable. However, this caused the above-mentioned issues.

The new method takes advantage of the fact that while the executable cannot be replaced or deleted, it can still be renamed. The current update process on windows is as follows:
1. Delete `yt-dlp.exe.old` if it exists
2. Download the new version as `yt-dlp.exe.new`
3. Rename the running exe to `yt-dlp.exe.old`
4. Rename `yt-dlp.exe.new` to `yt-dlp.exe`
5. Open a shell that deletes `yt-dlp.exe.old` and terminate

While we still use a subprocess, the actual update is already done before the app terminates and the batch script does not print anything to stdout/stderr. So this solves all the above issues
3 years ago
pukkandan c19bc311cb
[cleanup] Refactor updater
The updater now uses `.update.run_update` and not `.update.update_self`.
Although I don't expect anyone to be using the updater via API, a wrapper `update_self` is provided for compatibility just in case
3 years ago
pukkandan e28f1c0ae8
[cleanup] Fix linter and some typos
* Also remove inconsistent use of `"` in setup.py
3 years ago
pukkandan c4a508ab31
[update] Fix updater removing the executable bit on some UNIX distros
Closes #133
3 years ago