Skip to content
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

Fix inconsistent executable target name #55

Merged
merged 3 commits into from
Jun 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -90,20 +90,6 @@
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "SwiftPackageListCommand"
BuildableName = "SwiftPackageListCommand"
BlueprintName = "SwiftPackageListCommand"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
Expand Down Expand Up @@ -210,16 +196,6 @@
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
<TestableReference
skipped = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "SwiftPackageListCommandTests"
BuildableName = "SwiftPackageListCommandTests"
BlueprintName = "SwiftPackageListCommandTests"
ReferencedContainer = "container:">
</BuildableReference>
</TestableReference>
<TestableReference
skipped = "NO">
<BuildableReference
Expand Down Expand Up @@ -250,6 +226,16 @@
ReferencedContainer = "container:">
</BuildableReference>
</TestableReference>
<TestableReference
skipped = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "swift-package-list-tests"
BuildableName = "swift-package-list-tests"
BlueprintName = "swift-package-list-tests"
ReferencedContainer = "container:">
</BuildableReference>
</TestableReference>
</Testables>
</TestAction>
<LaunchAction
Expand Down
30 changes: 17 additions & 13 deletions .swiftpm/xcode/xcshareddata/xcschemes/swift-package-list.xcscheme
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,20 @@
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "swift-package-list-tests"
BuildableName = "swift-package-list-tests"
BlueprintName = "swift-package-list-tests"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "NO"
Expand All @@ -28,9 +42,9 @@
buildForAnalyzing = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "SwiftPackageListCommandTests"
BuildableName = "SwiftPackageListCommandTests"
BlueprintName = "SwiftPackageListCommandTests"
BlueprintIdentifier = "SwiftPackageListTests"
BuildableName = "SwiftPackageListTests"
BlueprintName = "SwiftPackageListTests"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
Expand All @@ -42,16 +56,6 @@
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
<TestableReference
skipped = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "SwiftPackageListCommandTests"
BuildableName = "SwiftPackageListCommandTests"
BlueprintName = "SwiftPackageListCommandTests"
ReferencedContainer = "container:">
</BuildableReference>
</TestableReference>
<TestableReference
skipped = "NO">
<BuildableReference
Expand Down
14 changes: 7 additions & 7 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ let package = Package(
.watchOS(.v6),
],
products: [
.executable(name: "swift-package-list", targets: ["SwiftPackageListCommand"]),
.executable(name: "swift-package-list", targets: ["swift-package-list"]),
.plugin(name: "SwiftPackageListJSONPlugin", targets: ["SwiftPackageListJSONPlugin"]),
.plugin(name: "SwiftPackageListPropertyListPlugin", targets: ["SwiftPackageListPropertyListPlugin"]),
.plugin(name: "SwiftPackageListSettingsBundlePlugin", targets: ["SwiftPackageListSettingsBundlePlugin"]),
Expand All @@ -28,7 +28,7 @@ let package = Package(
],
targets: [
.executableTarget(
name: "SwiftPackageListCommand",
name: "swift-package-list",
dependencies: [
.target(name: "SwiftPackageListCore"),
.product(name: "ArgumentParser", package: "swift-argument-parser"),
Expand All @@ -37,22 +37,22 @@ let package = Package(
.plugin(
name: "SwiftPackageListJSONPlugin",
capability: .buildTool(),
dependencies: [.target(name: "SwiftPackageListCommand")]
dependencies: [.target(name: "swift-package-list")]
),
.plugin(
name: "SwiftPackageListPropertyListPlugin",
capability: .buildTool(),
dependencies: [.target(name: "SwiftPackageListCommand")]
dependencies: [.target(name: "swift-package-list")]
),
.plugin(
name: "SwiftPackageListSettingsBundlePlugin",
capability: .buildTool(),
dependencies: [.target(name: "SwiftPackageListCommand")]
dependencies: [.target(name: "swift-package-list")]
),
.plugin(
name: "SwiftPackageListPDFPlugin",
capability: .buildTool(),
dependencies: [.target(name: "SwiftPackageListCommand")]
dependencies: [.target(name: "swift-package-list")]
),
.target(
name: "SwiftPackageListCore",
Expand All @@ -65,7 +65,7 @@ let package = Package(
dependencies: ["SwiftPackageList"],
resources: [.process("Resources")]
),
.testTarget(name: "SwiftPackageListCommandTests"),
.testTarget(name: "swift-package-list-tests"),
.testTarget(
name: "SwiftPackageListCoreTests",
dependencies: ["SwiftPackageListCore"],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import XcodeProjectPlugin
extension SwiftPackageListJSONPlugin: XcodeBuildToolPlugin {
func createBuildCommands(context: XcodePluginContext, target: XcodeTarget) throws -> [Command] {
let projectPath = context.xcodeProject.directory.appending("\(context.xcodeProject.displayName).xcodeproj")
let executable = try context.tool(named: "SwiftPackageListCommand").path
let executable = try context.tool(named: "swift-package-list").path
let outputPath = context.pluginWorkDirectory
let fileType = "json"
return [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import XcodeProjectPlugin
extension SwiftPackageListPDFPlugin: XcodeBuildToolPlugin {
func createBuildCommands(context: XcodePluginContext, target: XcodeTarget) throws -> [Command] {
let projectPath = context.xcodeProject.directory.appending("\(context.xcodeProject.displayName).xcodeproj")
let executable = try context.tool(named: "SwiftPackageListCommand").path
let executable = try context.tool(named: "swift-package-list").path
let outputPath = context.pluginWorkDirectory
let fileType = "pdf"
return [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import XcodeProjectPlugin
extension SwiftPackageListPropertyListPlugin: XcodeBuildToolPlugin {
func createBuildCommands(context: XcodePluginContext, target: XcodeTarget) throws -> [Command] {
let projectPath = context.xcodeProject.directory.appending("\(context.xcodeProject.displayName).xcodeproj")
let executable = try context.tool(named: "SwiftPackageListCommand").path
let executable = try context.tool(named: "swift-package-list").path
let outputPath = context.pluginWorkDirectory
let fileType = "plist"
return [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import XcodeProjectPlugin
extension SwiftPackageListSettingsBundlePlugin: XcodeBuildToolPlugin {
func createBuildCommands(context: XcodePluginContext, target: XcodeTarget) throws -> [Command] {
let projectPath = context.xcodeProject.directory.appending("\(context.xcodeProject.displayName).xcodeproj")
let executable = try context.tool(named: "SwiftPackageListCommand").path
let executable = try context.tool(named: "swift-package-list").path
let outputPath = context.pluginWorkDirectory
let fileType = "settings-bundle"
return [
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// FileType+ExpressibleByArgument.swift
// SwiftPackageListCommand
// swift-package-list
//
// Created by Felix Herrmann on 19.05.22.
//
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// SwiftPackageList+Generate.swift
// SwiftPackageListCommand
// swift-package-list
//
// Created by Felix Herrmann on 21.05.23.
//
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// SwiftPackageList+Options.swift
// SwiftPackageListCommand
// swift-package-list
//
// Created by Felix Herrmann on 21.05.23.
//
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// SwiftPackageList+Scan.swift
// SwiftPackageListCommand
// swift-package-list
//
// Created by Felix Herrmann on 21.05.23.
//
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// SwiftPackageList.swift
// SwiftPackageListCommand
// swift-package-list
//
// Created by Felix Herrmann on 01.11.21.
//
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
//
// SwiftPackageListCommandTests.swift
// SwiftPackageListCommandTests
// ExecutionTests.swift
// swift-package-list-tests
//
// Created by Felix Herrmann on 18.05.22.
//

import XCTest

final class SwiftPackageListCommandTests: XCTestCase {
final class ExecutionTests: XCTestCase {

private var productsDirectory: URL {
for bundle in Bundle.allBundles where bundle.bundlePath.hasSuffix(".xctest") {
Expand Down