From a11927f788c6660a677c7bf7783daec7e46d222b Mon Sep 17 00:00:00 2001 From: Max Desiatov Date: Tue, 9 May 2023 16:40:14 +0100 Subject: [PATCH 1/3] Package.swift: make package name consistent with repo name Rest of SwiftPM packages provided by Apple follow a dash-case naming scheme consistent with repository name, usually with `swift-` prefix. This shouldn't have an impact on SwiftSyntax clients. For example `swift-format` already uses `package: "swift-syntax"` argument in its `Package.swift` for specifying the dependency. --- Package.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Package.swift b/Package.swift index d67c2ab8763..952a5c264ae 100644 --- a/Package.swift +++ b/Package.swift @@ -36,7 +36,7 @@ if ProcessInfo.processInfo.environment["SWIFTPARSER_ENABLE_ALTERNATE_TOKEN_INTRO } let package = Package( - name: "SwiftSyntax", + name: "swift-syntax", platforms: [ .macOS(.v10_15), .iOS(.v13), From ebf5ae1481c57c0afa06c107d9c3b4c70a8dd4cc Mon Sep 17 00:00:00 2001 From: Max Desiatov Date: Tue, 9 May 2023 20:11:11 +0100 Subject: [PATCH 2/3] Update build-script.py for `swift-syntaxPackageTests` --- build-script.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build-script.py b/build-script.py index 3d1c4256255..0afdff52b08 100755 --- a/build-script.py +++ b/build-script.py @@ -440,7 +440,7 @@ def run_xctests( if verbose: swiftpm_call.extend(["--verbose"]) - swiftpm_call.extend(["--test-product", "SwiftSyntaxPackageTests"]) + swiftpm_call.extend(["--test-product", "swift-syntaxPackageTests"]) env = dict(os.environ) env["SWIFT_BUILD_SCRIPT_ENVIRONMENT"] = "1" From af8a4c94990c1b11d167fad92c0adce4393837a0 Mon Sep 17 00:00:00 2001 From: Max Desiatov Date: Tue, 9 May 2023 20:11:59 +0100 Subject: [PATCH 3/3] Update LinkageTests.swift for `swift-syntaxPackageTests` --- Tests/SwiftParserTest/LinkageTests.swift | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Tests/SwiftParserTest/LinkageTests.swift b/Tests/SwiftParserTest/LinkageTests.swift index c17b92b3913..00cb3833141 100644 --- a/Tests/SwiftParserTest/LinkageTests.swift +++ b/Tests/SwiftParserTest/LinkageTests.swift @@ -200,9 +200,9 @@ extension LinkageTest { let name = try XCTUnwrap(_dyld_get_image_name(i)) let path = String(cString: name) // We can wind up in SwiftParserTest.xctest when built via the IDE or - // in SwiftSyntaxPackageTests.xctest when built at the command line + // in swift-syntaxPackageTests.xctest when built at the command line // via the package manager. - guard path.hasSuffix("SwiftParserTest") || path.hasSuffix("SwiftSyntaxPackageTests") else { + guard path.hasSuffix("SwiftParserTest") || path.hasSuffix("swift-syntaxPackageTests") else { continue }