Skip to content

Fix "minor" version dependency pinning #25

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 4, 2015

Conversation

nonsensery
Copy link

What's this PR do?

Fixes the pinning of dependencies with major and minor version numbers specified.

Where should the reviewer start?

The diff is just one line, but the change is significant. If the package manifest specifies both major and minor version numbers for a dependency, it should be pinned to only allow differences in the patch number.

How should this be manually tested?

  1. Create (or find) a package ("Package A") with tags for versions 1.0.0, 1.0.1 and 1.1.0.
  2. Create a package ("Package B") with a dependency on version 1.0.x of Package A.
    • For example: .Package("https://example.com/pkg-a.git", majorVersion: 1, minor: 0)
  3. Build Package B (or at least install its dependencies).
    • Afterwards, you should end up with version 1.0.1 of Package A, not version 1.1.0.

Any background context you want to provide?

Previously, there was no difference between a dependency specified with only a major version, and one specified with a major and minor version. Seems like probably just a copy-paste error.

If a major and minor version are provided, the version range should be
locked to patches of that minor version.
@nonsensery nonsensery changed the title Fix minor version dependency pinning Fix "minor" version dependency pinning Dec 4, 2015
mxcl added a commit that referenced this pull request Dec 4, 2015
@mxcl mxcl merged commit f6b6da9 into swiftlang:master Dec 4, 2015
@mxcl
Copy link
Contributor

mxcl commented Dec 4, 2015

Wonderful PR, thank you. It is truly a pleasure when so much information is provided.

aciidgh added a commit to aciidgh/swift-package-manager that referenced this pull request Jan 11, 2019
* [swift-bindings] Add to test target dependency only if swiftc is found

* [swift-bindings] don't assume build dir in swift-binding test
sergiocampama pushed a commit that referenced this pull request Apr 20, 2020
Split process output between stdout and stderr
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.

2 participants