diff --git a/Formula/jena.rb b/Formula/jena.rb index 25722fea16..3477f0fcc8 100644 --- a/Formula/jena.rb +++ b/Formula/jena.rb @@ -21,9 +21,9 @@ class Jena < Formula prefix.install %w{ LICENSE ReleaseNotes-Jena.txt NOTICE ReleaseNotes-TDB.txt README ReleaseNotes-ARQ.txt } doc.install ['javadoc-arq', 'javadoc-core', 'javadoc-sdb', 'javadoc-tdb', 'src-examples'] libexec.install Dir['*'] - Dir["#{libexec}/bin/*"].map { |p| Pathname.new p }.each { |path| - bin_name = path.basename + Dir["#{libexec}/bin/*"].each do |path| + bin_name = File.basename(path) (bin+bin_name).write shim_script(bin_name) - } + end end end diff --git a/Formula/luciddb.rb b/Formula/luciddb.rb index 24a7d1958c..784e92ecfc 100644 --- a/Formula/luciddb.rb +++ b/Formula/luciddb.rb @@ -24,7 +24,7 @@ class Luciddb < Formula end Dir["#{libexec}/bin/*"].each do |b| next if b =~ /classpath.gen/ or b =~ /defineFarragoRuntime/ - n = Pathname.new(b).basename + n = File.basename(b) (bin+n).write shim_script(n) end end diff --git a/Formula/node.rb b/Formula/node.rb index 451961ffcc..b4796cf8a8 100644 --- a/Formula/node.rb +++ b/Formula/node.rb @@ -66,7 +66,7 @@ class Node < Formula (lib/"node_modules/npm/npmrc").write("prefix = #{npm_prefix}\n") # Link npm manpages - Pathname.glob("#{lib}/node_modules/npm/man/*").each do |man| + Pathname.glob("#{lib}/node_modules/npm/man/*") do |man| dir = send(man.basename) man.children.each { |file| dir.install_symlink(file) } end diff --git a/Formula/zookeeper.rb b/Formula/zookeeper.rb index 1aebb89f19..8ec9a6c4b2 100644 --- a/Formula/zookeeper.rb +++ b/Formula/zookeeper.rb @@ -101,12 +101,12 @@ class Zookeeper < Formula (var+'run/zookeeper/data').mkpath # Install shim scripts to bin - Dir["#{libexec}/bin/*.sh"].map { |p| Pathname.new p }.each { |path| + Pathname.glob("#{libexec}/bin/*.sh") do |path| next if path == libexec+'bin/zkEnv.sh' script_name = path.basename bin_name = path.basename '.sh' (bin+bin_name).write shim_script(script_name) - } + end # Install default config files defaults = etc/'zookeeper/defaults'