Skip to content
Merged
Show file tree
Hide file tree
Changes from 6 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
23 changes: 23 additions & 0 deletions _includes/install/_linux_platforms_tabs.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,26 @@
## Latest Release
<ul class="grid-level-0 grid-layout-2-column">
<li class="grid-level-1 featured">
<h3>Swiftly (recommended)</h3>
<p class="description">
The Swiftly installer manages Swift and its dependencies. It supports switching between different versions and downloading updates.
</p>
<h4>License: <a href="https://raw.githubusercontent.com/swiftlang/swiftly/refs/heads/main/LICENSE.txt">Apache-2.0</a> | PGP: <a href="https://download.swift.org/swiftly/linux/swiftly-0.4.0-dev-x86_64.tar.gz.sig">Signature</a></h4>
<a href="https://download.swift.org/swiftly/linux/swiftly-0.4.0-dev-x86_64.tar.gz" class="cta-secondary">Download</a>
<a href="/install/linux/swiftly" class="cta-secondary">Instructions</a>
</li>
<li class="grid-level-1">
<h3>Container</h3>
<p class="description">
If you prefer a containerized environment, you can download the official container images for compiling and running Swift on a variety of distributions.
</p>
<a href="https://hub.docker.com/_/swift" class="cta-secondary external">Docker Hub</a>
<a href="/install/linux/docker" class="cta-secondary">Instructions</a>
</li>
</ul>

## Alternate installation options

<p id="platforms">Select Linux platform:</p>

<div class="interactive-tabs os">
Expand Down
1 change: 0 additions & 1 deletion install/linux/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,4 @@ title: Install Swift
---

{% include install/_os_tabs.md linux="true" %}

{% include install/_linux_platforms_tabs.md %}
48 changes: 48 additions & 0 deletions install/linux/swiftly/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
---
layout: page
title: Getting Started with Swiftly
---

Download swiftly from the [install page](/install).

Run the following command in your terminal, to configure swiftly for your account:

```
$ swiftly init
```

Once swiftly is installed you can use it to install the latest available swift toolchain like this:

```
$ swiftly install latest
Fetching the latest stable Swift release...
Installing Swift 6.0.1
Downloaded 488.5 MiB of 488.5 MiB
Extracting toolchain...
Swift 6.0.1 installed successfully!
$ swift --version
Swift version 6.0.1 (swift-6.0.1-RELEASE)
Target: x86_64-unknown-linux-gnu
```

Or, you can install (and use) a swift release:

```
$ swiftly install --use 5.10
$ swift --version
Swift version 5.10 (swift-5.10-RELEASE)
Target: x86_64-unknown-linux-gnu
```

There's also an option to install the latest snapshot release and get access to the latest features:

```
$ swiftly install main-snapshot
```

> Note: This last example just installed the toolchain. You can run "swiftly use" to switch to it and other installed toolchahins when you're ready.
25 changes: 18 additions & 7 deletions install/macos/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,27 +5,36 @@ title: Install Swift

{% include install/_os_tabs.md macos="true" %}

## Latest Release (Swift {{ site.data.builds.swift_releases.last.name }})

## Latest Release
<ul class="grid-level-0 grid-layout-2-column">
<li class="grid-level-1">
<h3>Xcode</h3>
<p class="description">
Download the latest version of Xcode, which is regularly refreshed with the latest Swift toolchain.
To develop with Swift for Apple platforms, download the latest version of Xcode, which is regularly refreshed with the latest Swift toolchain.
</p>
<a href="https://developer.apple.com/xcode/" class="cta-secondary external">Install Xcode</a>
</li>
<li class="grid-level-1 featured">
<h3>Swiftly</h3>
<p class="description">
To download toolchains from Swift.org, use the Swiftly toolchain installer. Swift.org toolchains include experimental features like Embedded Swift and support for WebAssembly.
</p>
<a href="https://download.swift.org/macos/swiftly.pkg" class="cta-secondary">Download</a>
<a href="/install/macos/swiftly" class="cta-secondary">Instructions</a>
</li>
</ul>


## Other Install Options
<ul class="grid-level-0 grid-layout-2-column">
<li class="grid-level-1">
<h3>Package Installer</h3>
<p class="description">
Toolchain package installer (.pkg)
The toolchain package installer (.pkg) that Swiftly automates is available as a stand-alone download.
</p>
<a href="https://download.swift.org/{{ site.data.builds.swift_releases.last.tag | downcase }}/xcode/{{ site.data.builds.swift_releases.last.tag }}/{{ site.data.builds.swift_releases.last.tag }}-osx.pkg" class="cta-secondary">Download Toolchain</a>
<a href="/install/macos/package_installer" class="cta-secondary">Instructions</a>
</li>
</ul>

<ul class="grid-level-0">
{% include install/_static_sdk_release.md %}
</ul>

Expand All @@ -40,6 +49,8 @@ title: Install Swift

Swift snapshots are prebuilt binaries that are automatically created from the branch. These snapshots are not official releases. They have gone through automated unit testing, but they have not gone through the full testing that is performed for official releases.

The easiest way to install development snapshots is with the Swiftly tool. Read more on the [instructions page](/install/macos/swiftly).

{% assign xcode_dev_builds = site.data.builds.development.xcode | sort: 'date' | reverse %}
{% assign xcode_6_1_builds = site.data.builds.swift-6_1-branch.xcode | sort: 'date' | reverse %}

Expand Down
51 changes: 51 additions & 0 deletions install/macos/swiftly/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
---
layout: page
title: Getting Started with Swiftly
---

Download swiftly from the [install page](/install).

Run the following command in your terminal, to configure swiftly for your account:

```
$ swiftly init
```

Once swiftly is installed you can use it to install the latest available swift toolchain like this:

```
$ swiftly install latest
Fetching the latest stable Swift release...
Installing Swift 6.0.1
Downloaded 1355.3 MiB of 1355.3 MiB
Installing package in user home directory...
installer: Package name is Swift Open Source Xcode Toolchain
installer: Upgrading at base path /Users/swift
installer: The upgrade was successful.
Swift 6.0.1 installed successfully!
$ swift --version
Apple Swift version 6.0.1 (swift-6.0.1-RELEASE)
Target: arm64-apple-macosx15.0
```

Or, you can install (and use) a swift release:

```
$ swiftly install --use 5.10
$ swift --version
Apple Swift version 5.10 (swift-5.10-RELEASE)
Target: arm64-apple-macosx15.0
```

There's also an option to install the latest snapshot release and get access to the latest features:

```
$ swiftly install main-snapshot
```

> Note: This last example just installed the toolchain. You can run "swiftly use" to switch to it and other installed toolchahins when you're ready.