Commit f513e8f0 authored by clarkda's avatar clarkda

Dont allow pod names that begin with a `.`

parent 2b500a99
......@@ -20,6 +20,13 @@ To install or update CocoaPods see this [guide](http://docs.cocoapods.org/guides
[Piet Brauer](https://github.com/pietbrauer)
[Orta Therox](https://github.com/orta)
* `pod lib create` now disallows any pod name that begins with a `.`
[Dustin Clark](https://github.com/clarkda)
[#2026](https://github.com/CocoaPods/CocoaPods/pull/2026)
[Core#97](https://github.com/CocoaPods/Core/pull/97)
[Core#98](https://github.com/CocoaPods/Core/issues/98)
## 0.31.1
[CocoaPods](https://github.com/CocoaPods/CocoaPods/compare/0.31.1...0.31.0)
[CocoaPods-Core](https://github.com/CocoaPods/Core/compare/0.31.1...0.31.0)
......
......@@ -26,6 +26,7 @@ module Pod
super
help! "A name for the Pod is required." unless @name
help! "The Pod name cannot contain spaces." if @name.match(/\s/)
help! "The Pod name cannot begin with a '.'" if @name[0, 1] == '.'
end
def run
......
......@@ -16,6 +16,10 @@ module Pod
lambda { run_command('lib', 'create', 'Pod Name With Spaces') }.should.raise CLAide::Help
end
it "complains if pod name begins with a period" do
lambda { run_command('lib', 'create', '.HiddenPod') }.should.raise CLAide::Help
end
it "should create a new dir for the newly created pod" do
@sut.any_instance.stubs(:configure_template)
url = @sut::TEMPLATE_REPO
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment