Skip to content

Commit d7b6924

Browse files
committed
Update Build.yml
1 parent cb1e0ce commit d7b6924

File tree

1 file changed

+10
-6
lines changed

1 file changed

+10
-6
lines changed

.github/workflows/Build.yml

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,18 +23,22 @@ jobs:
2323
with:
2424
dotnet-version: '8.0.x' # .NET version
2525

26-
- name: Install dependencies
26+
- name: Install MAUI workloads
2727
run: |
28-
dotnet restore # Restore project dependencies
29-
28+
dotnet workload install maui
29+
dotnet workload install maui-android maui-ios maui-maccatalyst maui-windows
30+
31+
- name: Restore dependencies
32+
run: dotnet restore
33+
3034
- name: Build project
3135
run: |
32-
dotnet build --configuration Release --target ${{ matrix.platform }} --no-restore # Build project for target platform
36+
dotnet build --configuration Release --framework ${{ matrix.platform }} --no-restore
3337
3438
- name: Publish for ${{ matrix.platform }}
3539
run: |
36-
dotnet publish --configuration Release --output ./publish --target ${{ matrix.platform }} --no-restore # Publish the app for the selected platform
37-
40+
dotnet publish --configuration Release --framework ${{ matrix.platform }} --output ./publish --no-restore
41+
3842
- name: Archive artifacts
3943
if: success() # Archive the build artifacts
4044
uses: actions/upload-artifact@v3

0 commit comments

Comments
 (0)