Skip to content
Snippets Groups Projects
Commit b08c0704 authored by Jack Nagel's avatar Jack Nagel
Browse files

Only ask for the stem once

parent 22038d52
No related branches found
No related tags found
No related merge requests found
......@@ -36,11 +36,11 @@ module Homebrew
:autotools
end
if fc.name.nil? or fc.name.to_s.strip.empty?
path = Pathname.new url
print "Formula name [#{path.stem}]: "
fc.name = __gets || path.stem
fc.path = Formula.path fc.name
if fc.name.nil? || fc.name.strip.empty?
stem = Pathname.new(url).stem
print "Formula name [#{stem}]: "
fc.name = __gets || stem
fc.path = Formula.path(fc.name)
end
# Don't allow blacklisted formula, or names that shadow aliases,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment