# \#commandplugin

**URL:** https://forums.swift.org/tag/commandplugin/718.md

[Latest](https://forums.swift.org/latest.md) · [Categories](https://forums.swift.org/categories.md) · [Tags](https://forums.swift.org/tags.md)

---

## [\[Pitch\] Package Manager Conditional Plugin](https://forums.swift.org/t/pitch-package-manager-conditional-plugin/86217)

<div class="topic-metadata">

**Author:** [@clive819](https://forums.swift.org/u/clive819)\
**Replies:** 10\
**Last updated:** [June 14, 2026, 7:40pm UTC](https://forums.swift.org/t/pitch-package-manager-conditional-plugin/86217 "2026-06-14T19:40:17Z")

</div>

Proposal: SE-NNNN Authors: Clive Liu Review Manager: TBD Status: Awaiting review Introduction This proposal extends the plugins parameter of SwiftPM target declarations to support platform and trait conditions, using t…

---

## [\[Pitch\] SwiftPM Plugins - Explicit BuildTool Sandbox Permissions](https://forums.swift.org/t/pitch-swiftpm-plugins-explicit-buildtool-sandbox-permissions/68963)

<div class="topic-metadata">

**Author:** [@nholloh](https://forums.swift.org/u/nholloh)\
**Replies:** 10\
**Last updated:** [March 31, 2026, 8:18pm UTC](https://forums.swift.org/t/pitch-swiftpm-plugins-explicit-buildtool-sandbox-permissions/68963 "2026-03-31T20:18:33Z")

</div>

Introduction Since there are multiple topics (1, 2) where people have stated interest in network access for Swift Package Manager Plugins, I wanted to bring them together and draft a first pitch for a discussion. Motiva…

---

## [Cross-compiling using Swift Build Command](https://forums.swift.org/t/cross-compiling-using-swift-build-command/79061)

<div class="topic-metadata">

**Author:** [@Eugene\_Gubin](https://forums.swift.org/u/Eugene_Gubin)\
**Replies:** 0\
**Last updated:** [April 3, 2025, 12:13pm UTC](https://forums.swift.org/t/cross-compiling-using-swift-build-command/79061 "2025-04-03T12:13:29Z")

</div>

When building package from CLI I can use --triple parameter to specify desired target. Can I do the same from build command plugin using PackagePlugin.PackageManager?

---

## [\[Pitch\] Build Progress Display Control for SwiftPM Plugins](https://forums.swift.org/t/pitch-build-progress-display-control-for-swiftpm-plugins/78678)

<div class="topic-metadata">

**Author:** [@kateinoigakukun](https://forums.swift.org/u/kateinoigakukun)\
**Replies:** 1\
**Last updated:** [March 22, 2025, 12:55pm UTC](https://forums.swift.org/t/pitch-build-progress-display-control-for-swiftpm-plugins/78678 "2025-03-22T12:55:00Z")

</div>

Hi everyone, this is a new pitch to provide a way to display better build progress with SwiftPM Command Plugins. See swiftlang/swift-package-manager#8383 for the implementation and visual before/after. swift-evolution…

---

## [How to debug a SwiftPM Command plugin that fails due to sandbox limitations, and not even print messages are visible](https://forums.swift.org/t/how-to-debug-a-swiftpm-command-plugin-that-fails-due-to-sandbox-limitations-and-not-even-print-messages-are-visible/75367)

<div class="topic-metadata">

**Author:** [@a4z](https://forums.swift.org/u/a4z)\
**Replies:** 0\
**Last updated:** [October 14, 2024, 2:36pm UTC](https://forums.swift.org/t/how-to-debug-a-swiftpm-command-plugin-that-fails-due-to-sandbox-limitations-and-not-even-print-messages-are-visible/75367 "2024-10-14T14:36:39Z")

</div>

Hi I have a command plugin that basically works It runs successfully if I disable the sandbox swift package --disable-sandbox plugin --allow-writing-to-package-directory plugin-name However, running the same command …

---

## [\`swift run\` from inside a command plugin: Bad idea or terrible idea?](https://forums.swift.org/t/swift-run-from-inside-a-command-plugin-bad-idea-or-terrible-idea/69678)

<div class="topic-metadata">

**Author:** [@carlynorama](https://forums.swift.org/u/carlynorama)\
**Replies:** 7\
**Last updated:** [January 28, 2024, 11:25pm UTC](https://forums.swift.org/t/swift-run-from-inside-a-command-plugin-bad-idea-or-terrible-idea/69678 "2024-01-28T23:25:22Z")

</div>

So let's say I have a bunch of tasks that are better suited to the abilities/permissiveness of a command plugin, but I do run them every time I build. What (other than the process environment issues which will cause bui…

---

## [Package-benchmark 0.6.0 released](https://forums.swift.org/t/package-benchmark-0-6-0-released/63103)

<div class="topic-metadata">

**Author:** [@hassila](https://forums.swift.org/u/hassila)\
**Replies:** 0\
**Last updated:** [February 13, 2023, 2:49pm UTC](https://forums.swift.org/t/package-benchmark-0-6-0-released/63103 "2023-02-13T14:49:25Z")

</div>

I'm happy to share a new version (0.6.0) of the package-benchmark SwiftPM command plugin - this release has one major feature and addresses one of the most common sources of confusion of the results - it's now based on t…

---

## [How can we test SwiftPM Plugins?](https://forums.swift.org/t/how-can-we-test-swiftpm-plugins/61279)

<div class="topic-metadata">

**Author:** [@mackoj](https://forums.swift.org/u/mackoj)\
**Replies:** 3\
**Last updated:** [July 27, 2023, 2:16am UTC](https://forums.swift.org/t/how-can-we-test-swiftpm-plugins/61279 "2023-07-27T02:16:25Z")

</div>

How can we test SPM Plugin? It does not seem to be possible to test plugins because we cannot import Plugins in Tests. Or am I missing something? Thanks,

---

## [How to link different versioning of dependencies for different pipelines?](https://forums.swift.org/t/how-to-link-different-versioning-of-dependencies-for-different-pipelines/65991)

<div class="topic-metadata">

**Author:** [@shilei365](https://forums.swift.org/u/shilei365)\
**Replies:** 0\
**Last updated:** [July 5, 2023, 2:30pm UTC](https://forums.swift.org/t/how-to-link-different-versioning-of-dependencies-for-different-pipelines/65991 "2023-07-05T14:30:35Z")

</div>

I am trying to use SwiftPM and Swift Package Plugin for our project which has multi stages and pipelines, for example nightly, stable. Currently, our project A uses an internal library called "MyModuleB" as dependency, …

---

## [Benchmark stable release](https://forums.swift.org/t/benchmark-stable-release/63902)

<div class="topic-metadata">

**Author:** [@hassila](https://forums.swift.org/u/hassila)\
**Replies:** 5\
**Last updated:** [March 28, 2023, 4:34pm UTC](https://forums.swift.org/t/benchmark-stable-release/63902 "2023-03-28T16:34:24Z")

</div>

Hi, We're happy to announce that Benchmark now has shipped with what we believe is an API stable interface (which follows semantic versioning) with significantly improved capabilities compared to the initial release las…

---

## [Benchmark package initial release](https://forums.swift.org/t/benchmark-package-initial-release/60535)

<div class="topic-metadata">

**Author:** [@hassila](https://forums.swift.org/u/hassila)\
**Replies:** 62\
**Last updated:** [March 23, 2023, 8:30am UTC](https://forums.swift.org/t/benchmark-package-initial-release/60535 "2023-03-23T08:30:53Z")

</div>

I'm happy to announce that a first release of the Benchmark SwiftPM command plugin is available which supports both macOS and Linux (tested on Ubuntu) with Swift 5.6 or later. There's a sample project showing various Be…

---

## [Context.tool(named: "ModelGenerator") works when run from Xcode, fails when run from terminal](https://forums.swift.org/t/context-tool-named-modelgenerator-works-when-run-from-xcode-fails-when-run-from-terminal/60347)

<div class="topic-metadata">

**Author:** [@tychop](https://forums.swift.org/u/tychop)\
**Replies:** 1\
**Last updated:** [September 28, 2022, 11:02am UTC](https://forums.swift.org/t/context-tool-named-modelgenerator-works-when-run-from-xcode-fails-when-run-from-terminal/60347 "2022-09-28T11:02:25Z")

</div>

So, I'm creating a swift package command plugin. It works perfectly when invoked from Xcode(14) when right clicking the package and select the command plugin. However.... When running from a terminal session using the …

---

## [XcodeCommandPlugin cannot write to package although same plugin on a spm target can](https://forums.swift.org/t/xcodecommandplugin-cannot-write-to-package-although-same-plugin-on-a-spm-target-can/59312)

<div class="topic-metadata">

**Author:** [@doozMen](https://forums.swift.org/u/doozMen)\
**Replies:** 3\
**Last updated:** [August 5, 2022, 7:07am UTC](https://forums.swift.org/t/xcodecommandplugin-cannot-write-to-package-although-same-plugin-on-a-spm-target-can/59312 "2022-08-05T07:07:15Z")

</div>

I have declared my plugin with write permissions to the package directory. After some digging I can find the package from the xcode project plugin working directory. But when trying to alter the package I do not have wri…
