1
0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2025-10-03 23:43:21 -04:00

Improve build/updater

* Fix `get_executable_path` in UNIX
* Update `x86.exe` correctly
* Exit immediately in windows once the update process starts so that the file handle is released correctly
* Show `exe`/`zip`/`source` and 32/64bit in verbose message
* Look for both `yt-dlp` and `youtube-dlc` in releases. This ensures that the updater will keep working when the binary name is changed to yt-dlp
* Disable pycryptodome in win_x86 since it causes `distutils.errors.DistutilsPlatformError: Microsoft Visual C++ 10.0 is required`
This commit is contained in:
pukkandan
2021-02-14 22:40:54 +05:30
parent 273762c8d0
commit e5813e53f0
6 changed files with 52 additions and 29 deletions

View File

@@ -5936,7 +5936,7 @@ def make_dir(path, to_screen=None):
def get_executable_path():
path = os.path.dirname(sys.argv[0])
if os.path.abspath(sys.argv[0]) != os.path.abspath(sys.executable): # Not packaged
if os.path.basename(sys.argv[0]) == '__main__': # Running from source
path = os.path.join(path, '..')
return os.path.abspath(path)