Skip to content

Commit

Permalink
Mercurial: install extensions
Browse files Browse the repository at this point in the history
  • Loading branch information
adamv committed Nov 5, 2012
1 parent 77e5bbd commit 327d45a
Showing 1 changed file with 14 additions and 4 deletions.
18 changes: 14 additions & 4 deletions Library/Formula/mercurial.rb
Expand Up @@ -9,7 +9,7 @@ class Mercurial < Formula

depends_on 'docutils' => :python if build.head? or build.include? 'doc'

option 'doc', "Build the documentation. Depends on 'docutils' module"
option 'doc', "Build the documentation"

def install
# Don't add compiler specific flags so we can build against
Expand All @@ -22,7 +22,7 @@ def install
system "make doc" if build.head? or build.include? 'doc'
system "make local"

libexec.install 'hg', 'mercurial'
libexec.install 'hg', 'mercurial', 'hgext'

# Symlink the hg binary into bin
bin.install_symlink libexec/'hg'
Expand All @@ -39,15 +39,25 @@ def install
end

def caveats
if build.head? then <<-EOS.undent
s = ''

s += <<-EOS.undent
Extensions have been installed to:
#{libexec}/hgext
EOS

if build.head? then s += <<-EOS.undent
Mercurial is required to fetch its own repository, so there are now two
installations of mercurial on this machine. If the previous installation
was done via Homebrew, the old version may need to be cleaned up and new
version linked:
brew cleanup mercurial && brew link mercurial
brew cleanup mercurial && brew link mercurial
EOS
end

return s
end

def test
Expand Down

0 comments on commit 327d45a

Please sign in to comment.