diff --git a/src/get-started/install/_get-sdk-linux.md b/src/get-started/install/_get-sdk-linux.md index 8585cb334c2..b8e7bb35d62 100644 --- a/src/get-started/install/_get-sdk-linux.md +++ b/src/get-started/install/_get-sdk-linux.md @@ -2,114 +2,99 @@ {% include docs/china-notice.md %} -On Linux, you have two ways you can install Flutter. +To install the Flutter SDK on your Linux system, use one of the following methods. -### Install Flutter using snapd +### Method 1: Install Flutter using snapd -The easiest way to install Flutter on Linux is by -using snapd. For more information, -check out [Installing snapd][]. +This offers the most direct method to install the Flutter SDK on your Linux system. -Once you have snapd, you can -[install Flutter using the Snap Store][], -or at the command line: +To learn about using snapd, check [Installing snapd][]. + +After you install `snapd`, [install Flutter from the Snap Store][] or +run the following command: ```terminal $ sudo snap install flutter --classic ``` {{site.alert.note}} - Once you install snap, - use the following command to display your Flutter SDK path: + After you install Flutter with `snapd`, + display your Flutter SDK path with the following command: ```terminal $ flutter sdk-path ``` -{{site.alert.end}} -### Install Flutter manually - -If you don't have `snapd`, or can't use it, -you can install Flutter using the following steps. +{{site.alert.end}} - 1. Download the following installation bundle to get the latest - {{site.sdk.channel}} release of the Flutter SDK: +### Method 2: Manual installation - [(loading...)](#){:.download-latest-link-{{os}}.btn.btn-primary} +If you aren't using `snapd`, follow these steps to install Flutter. - For other release channels, and older builds, - check out the [SDK archive][]. +1. Download the installation bundle for the latest + {{site.sdk.channel}} release of the Flutter SDK: - 1. Extract the file in the desired location. For example: + [(loading...)](#){:.download-latest-link-{{os}}.btn.btn-primary} - {% comment %} - Our JS also updates the filename in this template, - but it doesn't include the terminal formatting: + You can find older builds and other release channels in the [SDK archive][]. - {% prettify shell %} - $ cd ~/development - $ tar xf ~/Downloads/[[download-latest-link-filename]]flutter_{{os}}_vX.X.X-{{site.sdk.channel}}.tar.xz[[/end]] - {% endprettify %} - {% endcomment -%} +1. Extract the downloaded file to a location of your choice: ```terminal $ cd ~/development $ tar xf ~/Downloads/flutter_{{os}}_vX.X.X-{{site.sdk.channel}}.tar.xz ``` - - 1. Add the `flutter` tool to your path: + +1. Add the `flutter` tool to your path: ```terminal $ export PATH="$PATH:`pwd`/flutter/bin" ``` - This command sets your `PATH` variable for the - _current_ terminal window only. - To permanently add Flutter to your path, + This command sets your `PATH` environment variable for the current + terminal window only. + To add Flutter as permenant part of your path, check out [Update your path][]. - 1. Optionally, pre-download development binaries: - - The `flutter` tool downloads platform-specific - development binaries as needed. For scenarios - where pre-downloading these artifacts is preferable - (for example, in hermetic build environments, - or with intermittent network availability), iOS - and Android binaries can be downloaded ahead of time by running: +1. (Optional) Pre-download development binaries: ```terminal $ flutter precache ``` - For additional download options, - check out `flutter help precache`. - -You are now ready to run Flutter commands! + To find additional download options, run `flutter help precache`. {{site.alert.note}} - To update an existing version of Flutter, - check out [Upgrading Flutter][]. + To update an existing version of Flutter, see [Upgrading Flutter][]. {{site.alert.end}} +### Verify your install with `flutter doctor` -### Run flutter doctor - -Run the following command to see if there are any -dependencies you need to install to complete the setup -(for verbose output, add the `-v` flag): +After installing Flutter, run `flutter doctor`. ```terminal $ flutter doctor ``` -This command checks your environment and displays -a report to the terminal window. -The Dart SDK is bundled with Flutter; -it isn't necessary to install Dart separately. -Check the output carefully for other software you might -need to install or further tasks to perform (shown in **bold** text). +This command checks your environment and displays a report in the +terminal window. +Flutter bundles the Dart SDK. You don't need to install Dart. + +To get greater detail on what you need to fix, add the `-v` flag: + +```terminal +$ flutter doctor -v +``` + +Review the output for further tasks to perform. +An example would be the text shown in **bold**. + +The `flutter doctor -v` output might resemble the following: -For example: +{% comment %} +Need to use HTML for this code block to get the replacements +and boldface to work. +{% endcomment -%}
[-] Android toolchain - develop for Android devices @@ -119,17 +104,15 @@ For example: visit {{site.url}}/setup/#android-setup for detailed instructions.-The following sections describe how to perform -these tasks and finish the setup process. +The following sections describe how to perform these tasks and finish the setup process. -Once you have installed any missing dependencies, -run the `flutter doctor` command again to verify -that you've set everything up correctly. +After installing any missing dependencies, +run the `flutter doctor` command again. {% include_relative _analytics.md %} [Flutter repo]: {{site.repo.flutter}} -[install Flutter using the Snap Store]: https://snapcraft.io/flutter +[install Flutter from the Snap Store]: https://snapcraft.io/flutter [Installing snapd]: https://snapcraft.io/docs/installing-snapd [SDK archive]: {{site.url}}/release/archive [Update your path]: #update-your-path diff --git a/src/get-started/install/linux.md b/src/get-started/install/linux.md index 19f2c842c48..55e9c3ba383 100644 --- a/src/get-started/install/linux.md +++ b/src/get-started/install/linux.md @@ -1,6 +1,6 @@ --- -title: Linux install -description: How to install on Linux. +title: Linux Installation Guide +description: Learn how to install Flutter on Linux. short-title: Linux next: title: Set up an editor @@ -12,12 +12,11 @@ next: ## System requirements To install and run Flutter, -your development environment must meet these minimum requirements: +your Linux development environment needs to meet these minimum requirements: -- **Operating Systems**: Linux (64-bit) -- **Disk Space**: 600 MB (does not include disk space for IDE/tools). -- **Tools**: Flutter depends on these command-line tools being available - in your environment. +- **Operating System**: Linux (64-bit) +- **Disk Space**: At least 600 MB (excluding disk space for IDE/tools). +- **Tools**: Flutter relies on these command-line tools: - `bash` - `curl` - `file` @@ -28,11 +27,10 @@ your development environment must meet these minimum requirements: - `which` - `xz-utils` - `zip` - -- **Shared libraries**: Flutter `test` command depends on this library - being available in your environment. - - `libGLU.so.1` - provided by mesa packages such as `libglu1-mesa` on - Ubuntu/Debian and `mesa-libGLU` on Fedora. +- **Shared libraries**: To utilize the `flutter test` command, + your environment needs the library `libGLU.so.1`. + The `mesa` packages provide this library: + `libglu1-mesa` on Ubuntu/Debian and `mesa-libGLU` on Fedora. {% include_relative _get-sdk-linux.md %}