0321 from macmini

This commit is contained in:
2025-03-21 13:28:36 +08:00
commit cd1fd4bdfa
11397 changed files with 4528845 additions and 0 deletions

View File

@ -0,0 +1,29 @@
# Update this when new version is tagged.
import os
import subprocess
LAST_TAG = 'v2.9.0'
def _get_git_version():
plugin_path = os.path.realpath(os.path.dirname(__file__))
try:
git_version = subprocess.check_output(
['git', 'describe', '--tags', '--abbrev=4', '--dirty=-*'],
stderr=subprocess.DEVNULL,
cwd=plugin_path)
if isinstance(git_version, bytes):
return git_version.decode('utf-8').rstrip()
else:
return git_version.rstrip()
except subprocess.CalledProcessError:
# print('Git version check failed: ' + str(e))
pass
except Exception:
# print('Git process cannot be launched: ' + str(e))
pass
return None
version = _get_git_version() or LAST_TAG