You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In this project, theres the library that a project can use, and then an example application. As someone who is using Jay as a dependency, I don't care to compile JayExample when I run swift build. Jay should be able to specify which files, folders, or targets to exclude when being built as a dependency. However, if I'm working on Jay, or checking it out, and I'm in a checkout of Jay, I wouldn't want to exclude JayExample from building (which is why the existing exclude doesn't work; if ALWAYS excludes those files). I would imagine the Package file for Jay should look something like this:
I agree this is a useful problem to solve, I'm not sure what form it should take.
One could also argue that we should have explicit dependencies from the consuming packages to the targets in the producing package, and if we did that then clients just wouldn't depend on the example target, so it wouldn't be built. That is my default inclination here...
This is going to be very important moving forward. I agree with Daniel here that the solution should involve being able to define the dependencies in more detail.
Additional Detail from JIRA
md5: fc4848b9eecc355917c37c020b3d4cab
is duplicated by:
relates to:
Issue Description:
Lets take the following project as an example: https://github.com/czechboy0/Jay/blob/master/Package.swift
In this project, theres the library that a project can use, and then an example application. As someone who is using Jay as a dependency, I don't care to compile JayExample when I run swift build. Jay should be able to specify which files, folders, or targets to exclude when being built as a dependency. However, if I'm working on Jay, or checking it out, and I'm in a checkout of Jay, I wouldn't want to exclude JayExample from building (which is why the existing exclude doesn't work; if ALWAYS excludes those files). I would imagine the Package file for Jay should look something like this:
The text was updated successfully, but these errors were encountered: