2018-05-15 11:26:34 +01:00
|
|
|
# swift
|
|
|
|
|
|
|
|
> Create, run and build Swift projects.
|
2019-06-03 01:06:36 +01:00
|
|
|
> More information: <https://swift.org>.
|
2018-05-15 11:26:34 +01:00
|
|
|
|
2021-09-12 15:03:27 +01:00
|
|
|
- Start a REPL (interactive shell):
|
2018-05-15 11:26:34 +01:00
|
|
|
|
|
|
|
`swift`
|
|
|
|
|
|
|
|
- Execute a program:
|
|
|
|
|
|
|
|
`swift {{file.swift}}`
|
|
|
|
|
|
|
|
- Start a new project with the package manager:
|
|
|
|
|
|
|
|
`swift package init`
|
|
|
|
|
|
|
|
- Generate an Xcode project file:
|
|
|
|
|
|
|
|
`swift package generate-xcodeproj`
|
|
|
|
|
|
|
|
- Update dependencies:
|
|
|
|
|
|
|
|
`swift package update`
|
|
|
|
|
|
|
|
- Compile project for release:
|
|
|
|
|
|
|
|
`swift build -c release`
|