How do I build an executable for an application written in Swift from the terminal?
问题 I'm asking how to do this outside of Xcode. A Swift script written in a text editor can be executed with xcrun swift hello_world.swift or swift hello_world.swift . They can also be set to executable and run with a shebang. This is parallel to a scripting language like Python. But since Swift is a compiled language, I'm sure there has to be some way of building a Swift executable through the Terminal using swift , clang , etc. Has anyone found anything regarding this? I've surprisingly found