aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorMartin Kühl2011-03-27 22:14:16 +0200
committerAdam Vandenberg2011-04-09 09:43:48 -0700
commit413cd1e1d30338e5ede3886759ce3f1a755b43e0 (patch)
tree5ff027b48b7a0171f0b1f5aad28a2a1ce7a8bfaf /Library
parent45bff20c22bb8b97623e7f1359949e47df10fb2d (diff)
downloadhomebrew-413cd1e1d30338e5ede3886759ce3f1a755b43e0.tar.bz2
Fix formula paths for manually specified names.
When the name of a new formula can't be autodetected, it defaults to the empty string. When it then gets read from user input later on, the new name is used but the formula path, based on the name, stays empty. This change sets the path after a new name was read. Signed-off-by: Adam Vandenberg <flangy@gmail.com>
Diffstat (limited to 'Library')
-rw-r--r--Library/Homebrew/cmd/create.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/Library/Homebrew/cmd/create.rb b/Library/Homebrew/cmd/create.rb
index d69ec2aba..d92dc0b00 100644
--- a/Library/Homebrew/cmd/create.rb
+++ b/Library/Homebrew/cmd/create.rb
@@ -24,6 +24,7 @@ module Homebrew extend self
path = Pathname.new url
print "Formula name [#{path.stem}]: "
fc.name = __gets || path.stem
+ fc.path = Formula.path fc.name
end
unless ARGV.force?
@@ -58,7 +59,7 @@ class FormulaCreator
attr :url
attr :md5
attr :name, true
- attr :path
+ attr :path, true
attr :mode, true
def url= url