aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula
diff options
context:
space:
mode:
Diffstat (limited to 'Library/Formula')
-rw-r--r--Library/Formula/npm.rb16
1 files changed, 9 insertions, 7 deletions
diff --git a/Library/Formula/npm.rb b/Library/Formula/npm.rb
index bd02657e4..f8856a914 100644
--- a/Library/Formula/npm.rb
+++ b/Library/Formula/npm.rb
@@ -1,13 +1,15 @@
require 'formula'
class Npm <Formula
- url 'http://github.com/isaacs/npm/tarball/v0.2.1'
+ url 'http://github.com/isaacs/npm/tarball/v0.2.2'
homepage 'http://github.com/isaacs/npm'
- md5 '345410d5d2ad3fb85316649b0d731144'
+ md5 'c61aaff07b6b66c3f4db26076dc0ec2d'
head 'git://github.com/isaacs/npm.git'
depends_on 'node'
+ skip_clean 'share/npm/bin'
+
def executable; <<-EOS
#!/bin/sh
exec "#{libexec}/cli.js" "$@"
@@ -15,11 +17,11 @@ EOS
end
def node_lib
- HOMEBREW_PREFIX+"lib/node"
+ lib + "node"
end
def share_bin
- HOMEBREW_PREFIX+"share/npm/bin"
+ share + "npm/bin"
end
def install
@@ -38,12 +40,12 @@ EOS
# add "npm-" prefix to man pages link them into the libexec man pages
man1.mkpath
- Dir.chdir libexec+"man" do
+ Dir.chdir libexec + "man1" do
Dir["*"].each do |file|
if file == "npm.1"
- ln_s "#{libexec}/man/#{file}", man1
+ ln_s "#{Dir.pwd}/#{file}", man1
else
- ln_s "#{libexec}/man/#{file}", "#{man1}/npm-#{file}"
+ ln_s "#{Dir.pwd}/#{file}", "#{man1}/npm-#{file}"
end
end
end