mirror of
https://github.com/Genshin-bots/gsuid_core.git
synced 2025-05-12 06:55:49 +08:00
🎨 core全部更新
时有概率产生报错
This commit is contained in:
parent
9e6b5f0418
commit
e3389087e1
@ -48,7 +48,7 @@ class GsClient:
|
||||
intent = await self._input()
|
||||
content = Message(type='text', data=intent)
|
||||
group_id = random.choice(['8888', '88888'])
|
||||
user_id = random.choice(['99999', '9999', '66666', '555'])
|
||||
user_id = random.choice(['99999'])
|
||||
msg = MessageReceive(
|
||||
bot_id='console',
|
||||
# bot_id='qqgroup',
|
||||
|
@ -384,10 +384,16 @@ def update_from_git(
|
||||
logger.info(f'[更新][{plugin_name}] 正在执行 git fetch')
|
||||
o.fetch()
|
||||
|
||||
default_branch_ref = repo.git.symbolic_ref('refs/remotes/origin/HEAD')
|
||||
default_branch = default_branch_ref.split('/')[-1] # 提取主分支名称
|
||||
try:
|
||||
default_branch_ref = repo.git.symbolic_ref('refs/remotes/origin/HEAD')
|
||||
default_branch = default_branch_ref.split('/')[-1] # 提取主分支名称
|
||||
|
||||
commits_diff = list(repo.iter_commits(f'HEAD..origin/{default_branch}'))
|
||||
commits_diff = list(
|
||||
repo.iter_commits(f'HEAD..origin/{default_branch}')
|
||||
)
|
||||
except GitCommandError as e:
|
||||
logger.warning(f'[更新] 查找默认分支失败...{e}!')
|
||||
commits_diff = list(repo.iter_commits(max_count=40))
|
||||
|
||||
if level >= 2:
|
||||
logger.warning(f'[更新][{plugin_name}] 正在执行 git clean --xdf')
|
||||
|
Loading…
x
Reference in New Issue
Block a user