Skip to content

Remove Demo/Pods dir#309

Merged
timbodeit merged 4 commits intotombenner:masterfrom
timbodeit:RemovePodsDir
Nov 6, 2015
Merged

Remove Demo/Pods dir#309
timbodeit merged 4 commits intotombenner:masterfrom
timbodeit:RemovePodsDir

Conversation

@timbodeit
Copy link
Copy Markdown
Collaborator

Personally I'm not a big fan of including copies of the full source of all the dependencies inside a frameworks repository.
In my opinion pull requests should be as small as possible, focus on the actual changes and not be cluttered by code changes from dependencies.

The .travis.yml already includes a pod install call and the Readme already advises the user to run pod install manually before trying out the Demo project.

Alongside this, I added a few other things to the .gitignore that I find reasonable and removed an xccheckout file.

@timbodeit
Copy link
Copy Markdown
Collaborator Author

@tombenner @Stunner Please have a look over this.

@tombenner
Copy link
Copy Markdown
Owner

LGTM, but it'd be good to get another pair of eyes on it, too 👍

@Stunner
Copy link
Copy Markdown
Collaborator

Stunner commented Nov 6, 2015

Encountered this error when running pod install:

For more information see http://blog.cocoapods.org
and the CHANGELOG for this version http://git.io/BaH8pQ.

Pre-downloading: `NUIParse` from `https://github.com/tombenner/NUIParse`
[!] Unable to satisfy the following requirements:

- `NUIParse (from `https://github.com/tombenner/NUIParse`)` required by `Podfile`
- `NUIParse (= 1.2)` required by `Podfile.lock`

Remove Podfile.lock from the repo as well and this pull request should be good to merge in.

@timbodeit
Copy link
Copy Markdown
Collaborator Author

I wouldn't remove the entire lockfile, as its a good reference what versions were actually used and causes the CI server to use the same ones.

The reason this was throwing an error is that the Podfile.lock was outdated. The Podfile was specifying to use the latest commit on master of tombenner/NUIParse. However the lockfile specified a specific version, that is older than the current one.

What I did instead was to remove the git url from the Podfile and update the Podfile.lock

@Stunner
Copy link
Copy Markdown
Collaborator

Stunner commented Nov 6, 2015

Interesting, I thought the Podfile.lock was always generated based on the contents of the Podfile. I thought it was a one way street. Didn't think the information of the Podfile.lock would matter much given that a pod install would overwrite it anyway.

@timbodeit
Copy link
Copy Markdown
Collaborator Author

pod install does not overwrite version numbers. That's what pod update is for.

pod install will install all dependencies from the Podfile in accordance with Podfile.lock, choosing older versions of Pods as required.
pod update will install the newest versions of all dependencies allowed by the Podfile ignoring the Podfile.lock.

That's the entire purpose of the lockfile. It gives you a way of making sure everybody is using the same versions without checking in all of the dependency code. Instead when you want to update the used version of a specific pod, commit those changes to the Podfile.lock

timbodeit added a commit that referenced this pull request Nov 6, 2015
@timbodeit timbodeit merged commit d8b1b08 into tombenner:master Nov 6, 2015
@timbodeit timbodeit deleted the RemovePodsDir branch November 6, 2015 08:52
@Stunner
Copy link
Copy Markdown
Collaborator

Stunner commented Nov 6, 2015

Good to know. I had always been doing that via the Podfile. Thanks for sharing.

@timbodeit
Copy link
Copy Markdown
Collaborator Author

Well normally I use a combination of the two. The Podfile and more important the podspecs of any Pods could have a loose version requirement (e.g. by using the ~> operator) and the Lockfile would help me get the exact version I was using in previous development when checking out an older commit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants