From 1637d68e469fb345eb865a80f09c4bcaa3a01c90 Mon Sep 17 00:00:00 2001 From: Adam Vandenberg Date: Sat, 25 Feb 2012 16:53:55 -0800 Subject: bagit: move conf out of bin --- Library/Formula/bagit.rb | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'Library/Formula') diff --git a/Library/Formula/bagit.rb b/Library/Formula/bagit.rb index e7cd37d6d..eee96f6bb 100644 --- a/Library/Formula/bagit.rb +++ b/Library/Formula/bagit.rb @@ -9,10 +9,17 @@ class Bagit < Formula def install prefix.install %w{conf logs} + libexec.install Dir['lib/*'] - inreplace "bin/bag", "$APP_HOME/lib", "$APP_HOME/libexec" + + # Point to libexec, and move conf file + inreplace "bin/bag" do |s| + s.gsub! "$APP_HOME/lib", "$APP_HOME/libexec" + s.gsub! "/bin/$APP_NAME.classworlds.conf", "/conf/$APP_NAME.classworlds.conf" + end inreplace "bin/bag.classworlds.conf", "${app.home}/lib", "${app.home}/libexec" - rm "bin/bag.bat" - bin.install Dir['bin/*'] + + bin.install 'bin/bag' + (prefix+'conf').install 'bin/bag.classworlds.conf' end end -- cgit v1.2.3