Spaces:
Sleeping
Sleeping
Merge pull request #8 from Jordi577/bugfix_whitespace_in_path
Browse files"Fix: Handling Whitespace in Repository Paths to Prevent Git Exit Status 129"
52 unmodified lines535455565758596061626352 unmodified linestry:if os.path.exists(repo_path):logging.info(f"Updating existing repository for {language}")update_command = f"cd {repo_path} && git pull"subprocess.run(update_command, shell=True, check=True)else:logging.info(f"Cloning repository for {language}")clone_command = f"git clone https://github.com/tree-sitter/tree-sitter-{language} {repo_path}"subprocess.run(clone_command, shell=True, check=True)except subprocess.CalledProcessError as e:logging.error(f"Failed to clone/update repository for {language}. Error: {e}")52 unmodified lines535455565758596061626352 unmodified linestry:if os.path.exists(repo_path):logging.info(f"Updating existing repository for {language}")update_command = f'cd "{repo_path}" && git pull'subprocess.run(update_command, shell=True, check=True)else:logging.info(f"Cloning repository for {language}")clone_command = f'git clone https://github.com/tree-sitter/tree-sitter-{language} "{repo_path}"'subprocess.run(clone_command, shell=True, check=True)except subprocess.CalledProcessError as e:logging.error(f"Failed to clone/update repository for {language}. Error: {e}")
CodeParser.py+2-2