-
Notifications
You must be signed in to change notification settings - Fork 821
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
Supports specifying multiple package products #1395
Changes from 3 commits
a61cd9b
ca24850
9ac7549
be92f16
32ed8a8
29ee0d6
9785749
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -646,6 +646,7 @@ targets: | |
|
||
**Package dependency** | ||
- [ ] **product**: **String** - The product to use from the package. This defaults to the package name, so is only required if a Package has multiple libraries or a library with a differing name | ||
- [ ] **products**: **String** - A list of products to use from the package. This can be used when depending on multiple products from a package. | ||
|
||
```yaml | ||
packages: | ||
|
@@ -663,6 +664,21 @@ targets: | |
product: SPMUtility | ||
``` | ||
|
||
Depending on multiple products from a package: | ||
|
||
```yaml | ||
packages: | ||
FooFeature: | ||
path: Packages/FooFeature | ||
targets: | ||
App: | ||
dependencies: | ||
- package: FooFeature | ||
products: | ||
- FooDomain | ||
- FooUI | ||
Comment on lines
+675
to
+679
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. How can we handle if we want to do below case?
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. My thinking was that people would use dependencies:
- package: FooFeature
product: FooDomain
embed: true
- package: FooFeature
product: FooUI
embed: false Alternatively, products should be objects as shown below while also supporting products as plain strings. If both aren't supported, the benefit of So both of these would be valid: dependencies:
- package: FooFeature
products:
- name: FooDomain
embed: true
- name: FooUI
embed: false dependencies:
- package: FooFeature
products:
- FooDomain
- FooUI There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @simonbs the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @yonaskolb That's a good idea. I've added it in 9785749. |
||
``` | ||
|
||
### Config Files | ||
|
||
Specifies `.xcconfig` files for each configuration. | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IMO, we can deprecate
product
and we can setproducts
as standard way.@yonaskolb what do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we have to keep it around due to it's ability to set different options related to the dependency itself, like you mention below