Skip to content
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

[SR-4411] Make SwiftPM store relative paths in pins file #5051

Open
keith opened this issue Mar 29, 2017 · 1 comment
Open

[SR-4411] Make SwiftPM store relative paths in pins file #5051

keith opened this issue Mar 29, 2017 · 1 comment
Labels

Comments

@keith
Copy link
Collaborator

keith commented Mar 29, 2017

Previous ID SR-4411
Radar None
Original Reporter @keith
Type Bug
Additional Detail from JIRA
Votes 0
Component/s Package Manager
Labels Bug
Assignee None
Priority Medium

md5: 4b57bbefe479c59fe9732efd3e2b69a4

relates to:

  • SR-2917 Handle different URLs referring same package

Issue Description:

Currently if you define a package like this:

import PackageDescription

let package = Package(
    name: "Sonar-Example",

    dependencies: [
       .Package(url: "../", majorVersion: 0),
    ]
)

The Package.pins is stored as:

{
  "autoPin": true,
  "pins": [
    {
      "package": "Sonar",
      "reason": null,
      "repositoryURL": "/Users/ksmiley/dev/Sonar",
      "version": "0.1.0"
    }
  ],
  "version": 1
}

This isn't very portable for packages where you're using relative paths either for an example project, or with submodules. It would be nice if the pins file stored the original relative path (`../`) so that it would work on other clones.

@ankitspd
Copy link
Member

#1085 revealed the difficultly in fixing this bug right now.

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
@shahmishal shahmishal transferred this issue from apple/swift May 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants