mirror of
https://github.com/LucBerge/yt-dlp.git
synced 2025-03-17 19:57:52 +03:00
[build] Use workflow_dispatch
for release
This commit is contained in:
parent
13ab5fa586
commit
75b725a7cc
5 changed files with 36 additions and 21 deletions
|
@ -1,5 +1,6 @@
|
|||
#!/usr/bin/env python3
|
||||
from datetime import datetime
|
||||
import sys
|
||||
import subprocess
|
||||
|
||||
|
||||
|
@ -13,7 +14,10 @@ old_ver = '.'.join(old_version_list[:3])
|
|||
old_rev = old_version_list[3] if len(old_version_list) > 3 else ''
|
||||
|
||||
ver = datetime.utcnow().strftime("%Y.%m.%d")
|
||||
rev = str(int(old_rev or 0) + 1) if old_ver == ver else ''
|
||||
|
||||
rev = (sys.argv[1:] or [''])[0] # Use first argument, if present as revision number
|
||||
if not rev:
|
||||
rev = str(int(old_rev or 0) + 1) if old_ver == ver else ''
|
||||
|
||||
VERSION = '.'.join((ver, rev)) if rev else ver
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue