stencilproject / Stencil

Stencil is a simple and powerful template language for Swift.
https://stencil.fuller.li
BSD 2-Clause "Simplified" License
2.34k stars 224 forks source link

fixes Swift tools version #201

Closed nhgrif closed 6 years ago

nhgrif commented 6 years ago

I'm not sure if this was working for other people, but we are still finding a conflict between Commander & Stencil. When trying to resolve my dependencies using Swift tools version 4, this is the dependency graph I get:

└── Stencilhttps://github.com/kylef/Stencil.git@0.10.1 ├── PathKithttps://github.com/kylef/PathKit.git@0.8.0 │ └── Spectrehttps://github.com/kylef/Spectre.git@0.7.2 └── Spectrehttps://github.com/kylef/Spectre.git@0.7.2

Based on the documentation here: https://swift.org/blog/swift-package-manager-manifest-api-redesign/

Since Swift 3 Package Manager doesn’t understand the Swift 4 manifest format, it will automatically ignore the Git tags that contain a Swift 4 manifest. So, if a package upgrades to Swift 4 manifest, Swift 3 Package Manager will pick the last tag which contains the Swift 3 manifest. However, the Package Manager in Swift 4 will pick the latest available version, regardless of manifest version.

It sounds like because Stencil's Package specifies tools version 3, the tags in Spectre and PathKit which are specifying version 4 are getting ignored, thus causing a conflict between Stencil and Commander.

nhgrif commented 6 years ago

I'll reopen this when I've actually tested that it's working.

nhgrif commented 6 years ago

We are able to successfully pull in both commander and stencil now from this branch.

nhgrif commented 6 years ago

This PR now includes #196 in order to actually work for Swift 4.

djbe commented 6 years ago

Closing this as it's been fixed with 0.12.1, thank you for the PR though!