Skip to content

Commit

Permalink
vim: use block-style inreplace
Browse files Browse the repository at this point in the history
  • Loading branch information
jacknagel committed May 10, 2014
1 parent 0a91149 commit cad18c2
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Formula/vim.rb
Expand Up @@ -86,10 +86,10 @@ def install
py_prefix = `python -c "import sys; print(sys.prefix)"`.chomp
py3_prefix = `python3 -c "import sys; print(sys.prefix)"`.chomp
# Help vim find Python's dynamic library as absolute path.
inreplace "src/auto/config.mk", /-DDYNAMIC_PYTHON_DLL=\\".*\\"/,
%(-DDYNAMIC_PYTHON_DLL=\'\"#{py_prefix}/Python\"\')
inreplace "src/auto/config.mk", /-DDYNAMIC_PYTHON3_DLL=\\".*\\"/,
%(-DDYNAMIC_PYTHON3_DLL=\'\"#{py3_prefix}/Python\"\')
inreplace "src/auto/config.mk" do |s|
s.gsub! /-DDYNAMIC_PYTHON_DLL=\\".*\\"/, %(-DDYNAMIC_PYTHON_DLL=\'\"#{py_prefix}/Python\"\')
s.gsub! /-DDYNAMIC_PYTHON3_DLL=\\".*\\"/, %(-DDYNAMIC_PYTHON3_DLL=\'\"#{py3_prefix}/Python\"\')
end
end

system "make"
Expand Down

0 comments on commit cad18c2

Please sign in to comment.