Skip to content

Commit

Permalink
fix: error occurred when trying to apply patches
Browse files Browse the repository at this point in the history
git dependency with patches attached is now idempotent
between each sync.
  • Loading branch information
coolkiid committed Dec 10, 2024
1 parent a5b6ba1 commit 1547085
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions core/fetchers/git_fetcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,8 @@ async def fetch(self, root_dir, options, *args, **kwargs):
root_dir=root_dir, name=f'GIT-FETCHER-{self.component.name.replace("/", "_")}'
)

source_dir = os.path.abspath(source_dir)

if not is_git_root(source_dir):
cmd = f'git init {source_dir}'
await run_git_command(cmd, shell=True, stderr=subprocess.STDOUT)
Expand Down

0 comments on commit 1547085

Please sign in to comment.