main
RogerWork 10 months ago
parent 8b53aacc54
commit 7d755311ab
  1. 18
      update/utils/git_util.py

@ -39,7 +39,7 @@ class GitUtil:
# 获取指定版本的最新代码
def checkout_release(self):
local_repo = Repo(self.local_code_path)
r = local_repo.git.checkout(self.get_release())
r = local_repo.git.checkout(self.short_release)
print(r)
r = local_repo.git.pull()
print(r)
@ -134,14 +134,14 @@ class GitUtil:
if self.create_cine_sql():
self.write_cine_sql_by_mysql()
# 获取release信息
def get_release(self, _release=''):
if _release == '':
release = self.short_release
else:
release = _release
rel = Release.objects.filter(short_release=release).first()
return rel.release
# # 获取release信息
# def get_release(self, _release=''):
# if _release == '':
# release = self.short_release
# else:
# release = _release
# rel = Release.objects.filter(short_release=release).first()
# return rel.release
@staticmethod
def get_short_version():

Loading…
Cancel
Save