Skip git logic for casks as they don't need it for patch creation

Co-authored-by: MikeMcQuaid <125011+MikeMcQuaid@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot] 2025-08-29 08:50:38 +00:00 committed by Bevan Kay
parent 88b7d2900a
commit 6be546a5bc
No known key found for this signature in database
GPG Key ID: C55CB024B5314B57

View File

@ -120,15 +120,6 @@ module Homebrew
# Extract to destination # Extract to destination
stage_dir.mkpath stage_dir.mkpath
UnpackStrategy.detect(downloaded_path).extract_nestedly(to: stage_dir, verbose: true) UnpackStrategy.detect(downloaded_path).extract_nestedly(to: stage_dir, verbose: true)
return unless args.git?
ohai "Setting up Git repository"
cd(stage_dir) do
system "git", "init", "-q"
system "git", "add", "-A"
system "git", "commit", "-q", "-m", "brew-unpack"
end
end end
end end
end end