Skip to content

Commit

Permalink
keg: mkpath while linking {include,lib,share}/postgresql@X
Browse files Browse the repository at this point in the history
Signed-off-by: Michael Cho <michael@michaelcho.dev>
  • Loading branch information
cho-m committed Mar 28, 2024
1 parent c3094ac commit babb352
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion Library/Homebrew/keg.rb
Original file line number Diff line number Diff line change
Expand Up @@ -415,7 +415,14 @@ def link(verbose: false, dry_run: false, overwrite: false)
link_dir("etc", verbose:, dry_run:, overwrite:) { :mkpath }
link_dir("bin", verbose:, dry_run:, overwrite:) { :skip_dir }
link_dir("sbin", verbose:, dry_run:, overwrite:) { :skip_dir }
link_dir("include", verbose:, dry_run:, overwrite:) { :link }
link_dir("include", verbose:, dry_run:, overwrite:) do |relative_path|
case relative_path.to_s

Check warning on line 419 in Library/Homebrew/keg.rb

View check run for this annotation

Codecov / codecov/patch

Library/Homebrew/keg.rb#L419

Added line #L419 was not covered by tests
when %r{^postgresql@\d+/}
:mkpath
else
:link
end
end

link_dir("share", verbose:, dry_run:, overwrite:) do |relative_path|
case relative_path.to_s
Expand All @@ -429,6 +436,7 @@ def link(verbose: false, dry_run: false, overwrite: false)
/^fish/,
%r{^lua/}, # Lua, Lua51, Lua53 all need the same handling.
%r{^guile/},
%r{^postgresql@\d+/},
*SHARE_PATHS
:mkpath
else
Expand All @@ -452,6 +460,7 @@ def link(verbose: false, dry_run: false, overwrite: false)
/^ocaml/,
/^perl5/,
"php",
%r{^postgresql@\d+/},
/^python[23]\.\d+/,
/^R/,
/^ruby/
Expand Down

0 comments on commit babb352

Please sign in to comment.