Swift Language: How to easily install SWIFT on Linux

Swift is a general purpose, compiled programming language that has been developed by Apple for macOS, IOS, watchOS, tvOS and for Linux as well. Swift offers better security, performance & safety & allows us to write safe but strict code. Swift is also very easy to learn & has been compared to Python in terms of ease of learning & there are also plenty of resources available online to learn Swift, which also makes is more approachable.

As of now, Swift is only available for installation on Ubuntu for Linux platform. So in this tutorial, we are going to discuss how to install Swift on Linux, or to be more precise how to Install Swift on Ubuntu. So let’s start with the dependencies that are required to be installed on Ubuntu systems before we actually install Swift on Ubuntu.

install SWIFT on Linux

Install Dependencies

Three packages are required to be installed on Ubuntu systems to be able to install & use Swift. These packages are ‘clang, libicu-dev, & git’ . Install these packages from the terminal using the following command,

$ sudo apt-get install clang libicu-dev -y

We are now ready to install Swift on our Linux machines.

Download the Swift packages

We will need to download Swift packages from the official website. Package for Swift are available for Ubuntu 14.04, 16.04 & 16.10. Using the command (applicable to your OS) mentioned below , download the swift package,