These are not CLI shortcuts, but actual examples of full commands
It is a shortcut because in the most general case of multiple destinations that refer to the same triple, none of the commands you've listed so far will work.
I'm willing to take a bet that in practice 90%+ of destination bundles won't be completely self-contained and will need to fall back on tools from PATH .
If you limit it to tools that generate code, it's more like the opposite.
There's little value in not reusing tools like git , zip etc that are already installed on the user's machine and work perfectly fine.
Since nobody has suggested not using those particular non-code-generating tools, and I specifically said it would be fine to keep using those, it is disingenuous of you to keep mentioning them.
If tools from the existing environment can't be picked automatically, it will require destination bundles to become much larger by including all of the tools, and that implies hundreds of megabytes of binaries (if not more in a typical scenario) copied around, duplicating those available in PATH .
This is a giant exaggeration, it won't be more than tens.
As an alternative, users of destinations will need to maintain their own explicit toolset files that enumerate every single binary that a toolchain might use.
No, most tools are already packaged in the Swift toolchain and so will not need to be enumerated in a toolset.
And there's no way to enforce that none of the tools would launch something from PATH anyway.
Sure, but that's not an excuse for making the problem worse by not cleaning up what we can.
The issue is that we already found it too conservative while trying to implement it.
I find that hard to believe: what tool did you have a problem with?
This restriction is not cleanly enforceable,
I've pointed out exactly where in the SPM source many tools are looked up: it would be trivial to disable those, while I fully grant there are others we don't know about and cannot easily control.
while proving to be burdensome from maintenance and DX perspective.
I don't think it will be a burden and am prepared to chip in myself on getting SPM working this way.
Let me emphasize that most bundles will mostly use the existing tools from the Swift toolchain or supply their own code-generating tools, ie not git, zip, etc but the assembler or linker. This whole discussion is about what to do about the few exceptions, where for some reason SPM can't find some tool and currently falls back to the system PATH.
I believe it's a good precaution to disable such system lookups that we know about in those few exceptional situations, but maybe you disagree. I fully grant that it would not be a promise of no system lookups, as I originally noted, "It is not clear what all the tools pulled in are: I doubt even the toolchain authors know at this point."