[aide] task-optimize: 修复已实现:git add_all 方法排除 .lock 文件
This commit is contained in:
@@ -25,8 +25,8 @@ class GitIntegration:
|
||||
|
||||
def add_all(self) -> None:
|
||||
self.ensure_repo()
|
||||
# 使用 -A 确保删除的文件也被暂存
|
||||
result = self._run(["add", "-A"], check=False)
|
||||
# 使用 -A 确保删除的文件也被暂存,排除 .lock 文件避免锁文件被提交
|
||||
result = self._run(["add", "-A", "--", ".", ":!*.lock"], check=False)
|
||||
if result.returncode != 0:
|
||||
raise FlowError(_format_git_error("git add 失败", result))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user