-
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
Add git information to PD context #7202
Conversation
This adds a few bits of information about a package's git repository to the context accessible to package manifests: - the current commit - the current tag (if any) - whether or not there are uncommited changes rdar://111523616
@swift-ci please test |
@swift-ci please test windows |
@grynspan added you since you asked for this kind of functionality in the context of swift-testing, so trying to make sure we can cover your use case as well |
@swift-ci please test windows |
3 similar comments
@swift-ci please test windows |
@swift-ci please test windows |
@swift-ci please test windows |
This would definitely meet our needs and let us replace our GitStatus compiler plugin. Thanks! |
Co-authored-by: Max Desiatov <[email protected]>
@swift-ci please test |
@swift-ci please test windows |
A recent PR on Swift Package Manager (swiftlang/swift-package-manager#7202) added a `gitInformation` property to the package manifest's `Context` global. This property contains exactly the information we need from the GitStatus plugin. Let's remove it, then! Adopting the `gitInformation` property requires that we drop remaining support for Swift 5.10. We will continue to minimally support it in a separate Package.swift file (where we simply won't have git repo information at build time.) This PR does not strip out other 5.10 support code such as `XCTestScaffold`. Resolves rdar://121529847.
A recent PR on Swift Package Manager (swiftlang/swift-package-manager#7202) added a `gitInformation` property to the package manifest's `Context` global. This property contains exactly the information we need from the GitStatus plugin. Let's remove it, then! Adopting the `gitInformation` property requires that we drop remaining support for Swift 5.10. We will continue to minimally support it in a separate Package.swift file (where we simply won't have git repo information at build time.) This PR does not strip out other 5.10 support code such as `XCTestScaffold`. Resolves rdar://121529847.
This adds a few bits of information about a package's git repository to the context accessible to package manifests:
rdar://111523616