-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Use Local Version -- Case Sensitivity Problems #7931
Comments
I will take a look at this. |
There's a discrepancy between how case is being handle as an identifier/name in swift package manager, I will forward this issue to spm project and let their contributors decide the best course of action. |
Seems like there is a discrepancy between how SwiftPM is saving package identities (where it's forced to be lowercased via the |
How is it being "forced" in this context? Does SwiftPM actually need to lowercase the identities, or is that just convention? |
When initializing a |
Further investigation revealed that SwiftPM has two naming conventions for a package, one being the package identity and the other being the display name. The display name is intended to be used in UI as the name suggests, whereas referring to a package in all other cases should rely on the identity - including swift package command line arguments. The identity is created through parsing the URL of the package's repository (namely just picking off the end of the path and removing
There are some discrepancies within SwiftPM between its usage of the two, so I think an effort to be more clear on which is expected on the user's end would be a great help here. |
Describe the bug
Selecting
Use Local Version
for a package dependency is failing for me.I suspect that the problem relates to case sensitivity.
The VS Code Package Dependencies window shows the dependency name as
versionator
. The Package.swift file for dependency declares the package name as "Versionator". The local directory for the package is calledVersionator
.Performing this step results in the following error:
To Reproduce
Clone
git@github.com:elegantchaos/VersionatorTest
Checkout commit b5ffdc1354d68b46fc65793d8acea8e59eab163e
Clone
git@github.com:elegantchaos/Versionator
to a parallel directoryOpen VersionatorTest in vscode
Right click on versionator in the Package Dependencies list
Choose Use Local Version
select the local version of Versionator
Expected behavior
The Versionator package should be set into edit mode, pointing at the local checkout
Environment
Additional context
Running
swift package edit Versionator --path ../Versionator
myself from the terminal does work.The text was updated successfully, but these errors were encountered: