Create Getting Setup with Dart authored by Adam Haertter's avatar Adam Haertter
## Checking your Dart & Flutter versions
To see if you have Dart and Flutter installed, run:
```bash
dart --version
flutter --version
```
This should give the installed versions of each.
## Downloading the Dart SDK
(These steps are adapted from https://dart.dev/get-dart. If you need a more in-depth description, go there)
**(Do NOT do this on any lab machines, only on your personal virtual machine if you have been given one!)**
ON THE VIRTUAL MACHINES ONLY, run these commands:
```bash
sudo apt-get update
sudo apt-get install dart
```
Remember, do not use the sudo command on any of the university-owned lab machines. You should only use sudo on your personal VMs.
## Configuring the Dart SDK in IntelliJ
When opening IntelliJ, the IDE may still not realize that Dart has been installed. If you get the error saying that the Dart SDK has not been configured, you'll have to do it manually.
Go to File > Settings > Languages & Frameworks. From here, click on the option for Dart on the sidebar. Tick the checkbox that says "Enable Dart support for the project <project name>"
Now we need to locate the Dart SDK path and give this to IntelliJ. By default, the Dart SDK will download to `/opt/flutter/bin/cache/dart-sdk`
Make sure it is located here on your personal machine, but as the default install location, you shouldn't need to change this unless you specified a different install location. In that case, put the link to your personal Dart SDK.
Lastly, make sure you tick the checkboxes for the modules that need to have Dart support enabled. Click Apply, and the error should be resolved.
![image](uploads/d8a58339421d4daaa8b8082c937d8e94/image.png)
## Running the pub get
Navigate to the game_manager project folder in your terminal and run the following command:
```bash
flutter pub get
```
![pubget](uploads/adb64c82b231a706a3485216397b0a5f/pubget.png)
If you encounter an error about version solving failed, the pubspec.yaml was likely edited. This is okay, and you should run the following commands to resolve the issue:
```bash
flutter clean
flutter pub upgrade --major-versions
```
You should be good from here.
\ No newline at end of file