diff options
author | Yuri Victorovich <yuri@FreeBSD.org> | 2022-07-28 17:49:39 +0000 |
---|---|---|
committer | Yuri Victorovich <yuri@FreeBSD.org> | 2022-07-28 17:54:25 +0000 |
commit | e034480085e7a5ba65d0762c5929b7ed41883c08 (patch) | |
tree | 4bc9f4c068c0d1a0c636e9ede8de80820aa3fabe /www/yt-dlp | |
parent | d83151e9c1e20daa7047f375bdade0dac2c752eb (diff) | |
download | ports-e034480085e7a5ba65d0762c5929b7ed41883c08.tar.gz ports-e034480085e7a5ba65d0762c5929b7ed41883c08.zip |
www/yt-dlp: Customize the message recommeding to update yt-dlp
... for FreeBSD.
Diffstat (limited to 'www/yt-dlp')
-rw-r--r-- | www/yt-dlp/Makefile | 1 | ||||
-rw-r--r-- | www/yt-dlp/files/patch-yt__dlp_update.py | 13 |
2 files changed, 12 insertions, 2 deletions
diff --git a/www/yt-dlp/Makefile b/www/yt-dlp/Makefile index c0e696fb4d86..80d0a1dd34a3 100644 --- a/www/yt-dlp/Makefile +++ b/www/yt-dlp/Makefile @@ -1,5 +1,6 @@ PORTNAME= yt-dlp DISTVERSION= 2022.07.18 +PORTREVISION= 1 CATEGORIES= www MAINTAINER= yuri@FreeBSD.org diff --git a/www/yt-dlp/files/patch-yt__dlp_update.py b/www/yt-dlp/files/patch-yt__dlp_update.py index 605de73d672c..964f4d186e10 100644 --- a/www/yt-dlp/files/patch-yt__dlp_update.py +++ b/www/yt-dlp/files/patch-yt__dlp_update.py @@ -1,8 +1,8 @@ - this patch prevents -U from updating yt-dlp - it makes it "unrecognized" ---- yt_dlp/update.py.orig 2022-06-22 01:54:04 UTC +--- yt_dlp/update.py.orig 2022-07-18 00:03:50 UTC +++ yt_dlp/update.py -@@ -29,7 +29,7 @@ def _get_variant_and_executable_path(): +@@ -39,7 +39,7 @@ def _get_variant_and_executable_path(): path = os.path.dirname(__file__) if isinstance(__loader__, zipimporter): @@ -11,3 +11,12 @@ elif (os.path.basename(sys.argv[0]) in ('__main__.py', '-m') and os.path.exists(os.path.join(path, '../.git/HEAD'))): return 'source', path +@@ -64,7 +64,7 @@ _NON_UPDATEABLE_REASONS = { + **{variant: f'Auto-update is not supported for unpackaged {name} executable; Re-download the latest release' + for variant, name in {'win32_dir': 'Windows', 'darwin_dir': 'MacOS', 'linux_dir': 'Linux'}.items()}, + 'source': 'You cannot update when running from source code; Use git to pull the latest changes', +- 'unknown': 'It looks like you installed yt-dlp with a package manager, pip or setup.py; Use that to update', ++ 'unknown': 'Please use the command \'pkg upgrade yt-dlp\' to upgrade.', + 'other': 'It looks like you are using an unofficial build of yt-dlp; Build the executable again', + } + |