@@ -13,13 +13,15 @@ jobs:
1313 strategy :
1414 fail-fast : false
1515 matrix :
16- os : [ubuntu-22.04, windows-2022]
16+ # os: [ubuntu-22.04, windows-2022]
17+ os : [windows-2022]
1718 platform : [x64]
18- build-cfg : [Debug, DebugOpt, Release]
19+ # build-cfg: [Debug, DebugOpt, Release]
20+ build-cfg : [Release]
1921 include :
2022 - os : windows-2022
2123 platform : x64
22- build-cfg : Debug
24+ # build-cfg: Debug
2325
2426 runs-on : ${{ matrix.os }}
2527
3739 - uses : actions/checkout@v4
3840
3941 - name : Setup emsdk
40- uses : mymindstorm /setup-emsdk@v14
42+ uses : pyodide /setup-emsdk@v15
4143 with :
4244 version : ${{ env.EMSCRIPTEN_VERSION }}
4345 actions-cache-folder : emsdk-cache-${{ runner.os }}
@@ -70,10 +72,24 @@ jobs:
7072 shell : bash
7173 run : build/build.sh restore -platform $PLATFORM -configuration $BUILD_CONFIGURATION
7274
75+ - name : ENV Set
76+ shell : pwsh
77+ run : |
78+ $dir=$env:GITHUB_WORKSPACE
79+ $dir=$dir.replace("\","/")
80+ echo "SCRIPT_FOLDER=$dir" >> $env:GITHUB_ENV
81+
82+
7383 - name : Build
7484 shell : bash
7585 run : build/build.sh -platform $PLATFORM -build_only -configuration $BUILD_CONFIGURATION
7686
87+ - name : Debug Session
88+ shell : pwsh
89+ if : ${{ failure() && vars.DEBUG_FAIL == '1' }}
90+ run : ${{env.SCRIPT_FOLDER}}/.github/debug_ssh_start.ps1
91+
92+
7793 - name : Test (.NET)
7894 # Disable test for debug configs, since they take over 6 hours to complete
7995 if : matrix.build-cfg != 'Debug'
@@ -113,11 +129,8 @@ jobs:
113129 include/**/*.h
114130
115131 create_package :
116- runs-on : windows-2019
132+ runs-on : windows-2022
117133 needs : build
118- if : |
119- (github.event_name == 'push' && (github.ref == 'refs/heads/main' || contains(github.ref, 'nuget') || startsWith(github.ref, 'refs/tags/v'))) ||
120- (github.event.pull_request.head.repo.full_name != github.repository && (contains(github.event.pull_request.head.ref, 'nuget') || startsWith(github.event.pull_request.head.ref, 'refs/tags/v')))
121134
122135 env :
123136 DOTNET_NOLOGO : true
@@ -148,14 +161,3 @@ jobs:
148161 name : CppSharp.nupkg
149162 path : |
150163 artifacts/*.nupkg
151-
152- - name : Upload package to GitHub Packages
153- run : |
154- cd artifacts
155- dotnet nuget push "*.nupkg" --api-key ${{ secrets.GITHUB_TOKEN }} --source "https://nuget.pkg.github.com/mono/index.json" --skip-duplicate
156-
157- - name : Publish package to nuget.org
158- if : startsWith(github.ref, 'refs/tags/v')
159- run : |
160- cd artifacts
161- dotnet nuget push "*.nupkg" --api-key ${{ secrets.NUGET_API_KEY }} --source "https://api.nuget.org/v3/index.json" --skip-duplicate
0 commit comments