Skip to content

Commit

Permalink
Updated per @parlough review
Browse files Browse the repository at this point in the history
  • Loading branch information
atsansone committed May 29, 2024
1 parent 9cb0017 commit cccb688
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 26 deletions.
27 changes: 16 additions & 11 deletions src/_includes/install/linux.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,32 +32,35 @@ You need steps 1 to 3 only for the first install.
| sudo tee /etc/apt/sources.list.d/dart_stable.list
```

1. Use the `apt-get` command with [`sudo`][sudo] privileges.
1. Use the following `sudo apt-get` commands.

```console
$ sudo apt-get update && sudo apt-get install dart
```

### Install from a Debian package {:.no_toc}
### Install as a Debian package {:.no_toc}

To install the Dart SDK from a Debian package (`*.deb`).
To install the Dart SDK as a Debian package (`*.deb`),
perform the following steps.

1. Download the Dart SDK [Debian package](#){:.debian-link-stable}.

1. Install the `*.deb` package with `dpkg` with [`sudo`][sudo] privileges.
1. Use the `sudo dpkg` command to install the `*.deb` package.

```console
$ sudo dpkg -i dart_3.2.6-1_amd64.deb
$ sudo dpkg -i dart_3.4.0-1_amd64.deb
```

Substitute `dart_3.4.0-1_amd64.deb` with the current filename.

## Upgrade the Dart SDK {:.no_toc}

Use the same command that you used to install the SDK.

### Upgrade using `apt-get` {:.no_toc}

If you installed the Dart SDK with `apt-get`,
use the `apt-get` command with [`sudo`][sudo] privileges to upgrade.
use the following `sudo apt-get` commands.

```console
$ sudo apt-get update && sudo apt-get install dart
Expand All @@ -66,20 +69,22 @@ $ sudo apt-get update && sudo apt-get install dart
### Upgrade using `dpkg` {:.no_toc}

If you installed the Dart SDK with `dpkg`,
use the `dpkg` command with [`sudo`][sudo] privileges to upgrade.
use the `sudo dpkg` command.

```console
$ sudo dpkg -i dart_3.2.6-1_amd64.deb
```

Substitute `dart_3.4.0-1_amd64.deb` with the new upgrade's filename.

## Uninstall the Dart SDK {:.no_toc}

### Uninstall using `apt-get` {:.no_toc}

If you installed the Dart SDK with `apt-get`,
use the `apt-get` command with [`sudo`][sudo] privileges to uninstall.
use the `sudo apt-get remove` command.

1. Use the `apt-get remove` command.
1. Use the `sudo apt-get remove` command.

```console
$ sudo apt-get remove -y dart
Expand All @@ -94,9 +99,9 @@ use the `apt-get` command with [`sudo`][sudo] privileges to uninstall.
### Uninstall using `dpkg` {:.no_toc}

If you installed the Dart SDK with `dpkg`,
use the `dpkg --purge` command with [`sudo`][sudo] privileges to uninstall.
use the `sudo dpkg --purge` command.

1. Use the `dpkg --purge` command.
1. Use the `sudo dpkg --purge` command.

```console
$ sudo dpkg --purge dart
Expand Down
21 changes: 10 additions & 11 deletions src/_includes/install/windows.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ Chocolatey requires [elevated permissions].

1. Install Chocolatey.

1. Launch [Powershell] with elevated permissions.
1. Launch [PowerShell][] with elevated permissions.

```ps
C:\> choco install dart-sdk
PS C:\> choco install dart-sdk
```

### Change default install path {:.no_toc}
Expand All @@ -23,7 +23,7 @@ environment variable to your desired installation directory.
Verify you can run Dart.

```ps
C:\> dart --version
PS C:\> dart --version
Dart SDK version: 3.2.4 (stable) (Thu Dec 21 19:13:53 2023 +0000) on "win_x64"
```

Expand All @@ -40,33 +40,32 @@ add the SDK location to your PATH:

### Upgrade using Chocolatey {:.no_toc}

To upgrade the Dart SDK:
To upgrade the Dart SDK, use the following command.

```ps
C:\> choco upgrade dart-sdk
PS C:\> choco upgrade dart-sdk
```

### Uninstall using Chocolatey {:.no_toc}

To uninstall the Dart SDK, use [Chocolatey][Chocolatey].
Chocolatey requires [elevated permissions].
To uninstall the Dart SDK, perform the following steps.

1. Launch [Powershell][] with elevated permissions.
1. Launch [PowerShell][] with elevated permissions.

1. Use the following command.

```ps
C:\> choco uninstall dart-sdk
PS C:\> choco uninstall dart-sdk
```

1. Remove the Dart configuration files from your home directory.

```dart
C:\> Remove-Item -Recurse -Force ^
PS C:\> Remove-Item -Recurse -Force ^
-Path $env:LOCALAPPDATA\.dartServer,$env:APPDATA\.dart,$env:APPDATA\.dart-tool
```

[elevated permissions]: https://www.thewindowsclub.com/elevated-privileges-windows
[Powershell]: https://www.thewindowsclub.com/how-to-open-an-elevated-powershell-prompt-in-windows-10
[PowerShell]: https://www.thewindowsclub.com/how-to-open-an-elevated-powershell-prompt-in-windows-10
[Chocolatey]: https://chocolatey.org
[`ChocolateyToolsLocation`]: https://stackoverflow.com/questions/19752533/how-do-i-set-chocolatey-to-install-applications-onto-another-drive/68314437#68314437
8 changes: 4 additions & 4 deletions src/content/get-dart/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,10 @@ choose one of the following options:

1. [Build the SDK from source][build-source].

:::warning Notice
{% include './archive/_sdk-terms.md' %}
:::

{% comment %}
NOTE to editors: Keep the zip file link as the last thing in the paragraph,
so it's easy to find (but not more tempting than package managers).
Expand Down Expand Up @@ -94,10 +98,6 @@ run the same command to install the Dart SDK from your package manager.
{% include 'install/macos.md' %}
</div>

:::warning Notice
{% include './archive/_sdk-terms.md' %}
:::

## Release channel reference {:#release-channels}

{% for channel in channel-list %}
Expand Down

0 comments on commit cccb688

Please sign in to comment.