Skip to content
Snippets Groups Projects
Commit cf2a8913 authored by Mike McQuaid's avatar Mike McQuaid
Browse files

git_etc: create etc if it doesn't exist.

parent 167017f8
No related branches found
No related tags found
No related merge requests found
...@@ -94,11 +94,11 @@ class FormulaInstaller ...@@ -94,11 +94,11 @@ class FormulaInstaller
def git_etc_postinstall def git_etc_postinstall
return unless quiet_system 'git', '--version' return unless quiet_system 'git', '--version'
etc = HOMEBREW_PREFIX+'etc'
preinstall_branch = "#{f.name}-preinstall" preinstall_branch = "#{f.name}-preinstall"
default_branch = "#{f.name}-default" default_branch = "#{f.name}-default"
merged = false merged = false
etc.cd do f.etc.mkpath
f.etc.cd do
if quiet_system 'git', 'diff', '--exit-code', preinstall_branch if quiet_system 'git', 'diff', '--exit-code', preinstall_branch
quiet_system 'git', 'branch', default_branch quiet_system 'git', 'branch', default_branch
quiet_system 'git', 'branch', '-D', preinstall_branch quiet_system 'git', 'branch', '-D', preinstall_branch
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment