From 51bfc9baf949cad4aab478c56be731bc8139a298 Mon Sep 17 00:00:00 2001 From: Yelaman Yelmuratov Date: Sun, 19 May 2024 00:53:58 +0500 Subject: [PATCH] . e added android studio installation to actions --- .github/workflows/build_and_test.yml | 22 +++++++++++++++++++++ lib/src/reporters/diff_tool/diff_tools.dart | 2 +- 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build_and_test.yml b/.github/workflows/build_and_test.yml index c0f355f..c721635 100644 --- a/.github/workflows/build_and_test.yml +++ b/.github/workflows/build_and_test.yml @@ -40,6 +40,28 @@ jobs: fi shell: bash + - name: Setup Android Studio + run: | + if [[ "${{ runner.os }}" == "Linux" ]]; then + sudo snap install androidstudio --classic + elif [[ "${{ runner.os }}" == "macOS" ]]; then + brew install --cask android-studio + elif [[ "${{ runner.os }}" == "Windows" ]]; then + choco install androidstudio + fi + shell: bash + + - name: Verify Android Studio installation + run: | + if [[ "${{ runner.os }}" == "Linux" ]]; then + /snap/bin/studio --version + elif [[ "${{ runner.os }}" == "macOS" ]]; then + "/Applications/Android Studio.app/Contents/MacOS/studio" --version + elif [[ "${{ runner.os }}" == "Windows" ]]; then + "C:\\Program Files\\Android\\Android Studio\\bin\\studio64.exe" --version + fi + shell: bash + - name: Build and test run: | ./bash/build_and_test.sh diff --git a/lib/src/reporters/diff_tool/diff_tools.dart b/lib/src/reporters/diff_tool/diff_tools.dart index 6f802db..136f90f 100644 --- a/lib/src/reporters/diff_tool/diff_tools.dart +++ b/lib/src/reporters/diff_tool/diff_tools.dart @@ -18,7 +18,7 @@ final class MacDiffTools { /// `WindowsDiffTools` contains diff tools available on Windows. final class WindowsDiffTools { static const DiffInfo visualStudioCode = DiffInfo( - command: 'C:\\Program Files\\Microsoft VS Code\\Code.exe', + command: 'C:\\Program Files\\Microsoft VS Code\\bin\\code', arg: '-d', name: 'code', );