Skip to content

Commit

Permalink
GitHubCI: check XAML style before install NET6
Browse files Browse the repository at this point in the history
This way we save some CI time in case the XAML check fails.
  • Loading branch information
siwatanejo committed May 17, 2023
1 parent 274e2ef commit 059a1ef
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
- uses: actions/checkout@v1
with:
submodules: false
- name: Install dependencies
- name: Install prettier&commitlint dependencies
run: |
apt update
apt install --yes sudo
Expand All @@ -22,6 +22,12 @@ jobs:
- name: ownership workaround
run: git config --global --add safe.directory '*'

- name: Check XAML style with prettier
run: |
sudo npm install --save-dev prettier @prettier/plugin-xml
./node_modules/.bin/prettier --xml-whitespace-sensitivity ignore --tab-width 4 --prose-wrap preserve --write '**/*.xaml'
git diff --exit-code
- name: Install .NET6
run: |
apt update && apt install --yes sudo
Expand All @@ -36,11 +42,6 @@ jobs:
run: |
dotnet format whitespace ./src --folder
git diff --exit-code
- name: Check XAML style with prettier
run: |
sudo npm install --save-dev prettier @prettier/plugin-xml
./node_modules/.bin/prettier --xml-whitespace-sensitivity ignore --tab-width 4 --prose-wrap preserve --write '**/*.xaml'
git diff --exit-code
- name: Check if gitPush1by1 was used
if: github.event_name == 'pull_request'
run: |
Expand Down

0 comments on commit 059a1ef

Please sign in to comment.