diff --git a/core/gitee_to_obs.py b/core/gitee_to_obs.py index 73830471b3fa32173a5fc11ae840f2064cc2ec64..1461df737599dd8d5431f9bc362ee394f47b4e33 100644 --- a/core/gitee_to_obs.py +++ b/core/gitee_to_obs.py @@ -112,6 +112,11 @@ class SYNCCode(object): if repository_exist == 'exist': pull_result = str(self.cmd.ssh_cmd('git -C %s pull' % rpm_path)[1].strip()).split("'")[1] log.info(pull_result) + pull_result_last = str(self.cmd.ssh_cmd('git -C %s pull' % rpm_path)[1].strip()).split("'")[1] + if "Already" in pull_result_last: + log.info(pull_result_last) + else: + self._git_clone(self.repository, self.gitee_branch, rpm_path) else: self._git_clone(self.repository, self.gitee_branch, rpm_path)