Motivation:
list_topsorted_dependencies had multiple issues:
- it would list some executable targets (even in libs-only mode)
- it confused packages with modules
- it would also list dependencies from outside the current package
Modifications:
Address all of the above.
Result:
Script more useful, inside and outside of swift-nio.
Co-authored-by: David Evans <david.evans@blackpoint.co>
Motivation:
Newer versions of SwiftPM for the Swift 5 release have changed the output
format of swift package dump-package. This has broken our
list_topsorted_dependencies script. This script is highly useful, so we'd
like to keep it working.
The discussion on SR-9191 suggests that SwiftPM considers this format
changeable at any time, so we may need to make a change like this in future.
We may want to consider writing tests for this script to ensure its continued good functioning.
Modifications:
- Amended the jq scripts to parse the new JSON format.
Result:
list_topsorted_dependencies will work with Swift 5 development copies of
SwiftPM. Note that this will break this script with earlier copies of SwiftPM,
but as we only support Swift 5 on the master branch this change is safe to
make.
Motivation:
A number of users have asked for the ability to install SwiftNIO
via Cocoapods. This is an entirely reasonable request, so let's
do it.
Modifications:
- Added a script that can generate, and optionally upload,
podspecs.
- Made a slight modification to the dependency script to provide
target-specific dependencies.
Result:
Users can use cocoapods if they prefer.
Motivation:
Sometimes it's useful to know the top-sorted dependency order. For
example if you need to do something in an order where all dependencies
of a target have already previously processed.
Modifications:
added scripts/list_topsorted_dependencies.sh
Result:
can write other scripts that need top-sorted dependencies