diff options
author | pukkandan <pukkandan@gmail.com> | 2021-02-14 22:40:54 +0530 |
---|---|---|
committer | pukkandan <pukkandan@gmail.com> | 2021-02-15 15:41:40 +0530 |
commit | e5813e53f089e018606435926ae0e109c4838394 (patch) | |
tree | c00e8ba9d26dac6276cdef38e5eb3353d7cce17a /youtube_dlc/utils.py | |
parent | 273762c8d045ace16143a6614c8d258f02a8094b (diff) | |
download | hypervideo-pre-e5813e53f089e018606435926ae0e109c4838394.tar.lz hypervideo-pre-e5813e53f089e018606435926ae0e109c4838394.tar.xz hypervideo-pre-e5813e53f089e018606435926ae0e109c4838394.zip |
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`
Diffstat (limited to 'youtube_dlc/utils.py')
-rw-r--r-- | youtube_dlc/utils.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/youtube_dlc/utils.py b/youtube_dlc/utils.py index 8f051cd1b..5aaec4f17 100644 --- a/youtube_dlc/utils.py +++ b/youtube_dlc/utils.py @@ -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) |