-
Notifications
You must be signed in to change notification settings - Fork 1.4k
enable netrc on non-darwin platforms #3466
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
Conversation
motivation: * netrc functionality is useful on all platforms * underlying functionality is avaialbe via swiftlang/swift-tools-support-core#210 changes: * remove platforms restructions where appropriate * add test fixute that actually exercises the netrc parsing logic * adjust tests to run on all platforms
related to swiftlang/swift-tools-support-core#210 |
#else | ||
diagnostics.emit(error: "'--netrc-file' option is only supported on macOS >=10.13") | ||
#endif | ||
} |
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.
this is not meaningful any longer since SwiftPM is >= 10.15 and its supported on other platforms
#if os(macOS) // Netrc feature currently only supported on macOS | ||
authProvider = try? Netrc.load(fromFileAtPath: netrcFilePath).get() | ||
#endif | ||
// FIXME: should this handle the error more gracefully? |
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.
@neonichu do you know why the error is ignored here? topic for different PR, but curios
@@ -47,89 +47,50 @@ final class PackageToolTests: XCTestCase { | |||
let stdout = try execute(["--version"]).stdout | |||
XCTAssert(stdout.contains("Swift Package Manager"), "got stdout:\n" + stdout) | |||
} | |||
|
|||
func testNetrcSupportedOS() throws { |
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.
this is not meaningful any longer since SwiftPM is >= 10.15 and its supported on other platforms
try execute(["--netrc-file", netrcPath.pathString, "resolve"], packagePath: packageRoot) | ||
XCTAssert(true) | ||
|
||
fixture(name: "DependencyResolution/External/XCFramework") { packageRoot in |
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.
new fixtures that actually uses netrc :D
@swift-ci please smoke test |
motivation: * netrc functionality is useful on all platforms * underlying functionality is avaialbe via swiftlang/swift-tools-support-core#210 changes: * remove platforms restructions where appropriate * add test fixute that actually exercises the netrc parsing logic * adjust tests to run on all platforms
motivation:
changes: