@@ -34,29 +34,38 @@ jobs:
3434 - uses : egorpugin/sw-action@master
3535
3636 - name : build
37- if : matrix.os == 'windows-2022' || matrix.os == 'windows-2019'
37+ if : github.event_name != 'pull_request' && ( matrix.os == 'windows-2022' || matrix.os == 'windows-2019')
3838 run : ./sw -static -shared -platform x86,x64 -config d,r build
39+ - name : build-pr
40+ if : github.event_name == 'pull_request' && (matrix.os == 'windows-2022' || matrix.os == 'windows-2019')
41+ run : ./sw build
3942
4043 - name : build
41- if : matrix.os != 'windows-2022' && matrix.os != 'windows-2019'
44+ if : github.event_name != 'pull_request' && ( matrix.os != 'windows-2022' && matrix.os != 'windows-2019')
4245 run : ./sw -static -shared -config d,r build -Dwith-tests=1
46+ - name : build-pr
47+ if : github.event_name == 'pull_request' && (matrix.os != 'windows-2022' && matrix.os != 'windows-2019')
48+ run : ./sw build -Dwith-tests=1
4349
4450 - name : download test data
4551 run : git clone https://github.com/egorpugin/tessdata tessdata_unittest
4652
4753 - name : copy fonts
4854 if : matrix.os != 'windows-2022' && matrix.os != 'windows-2019'
4955 run : cp tessdata_unittest/fonts/* test/testing/
50-
5156 - name : copy fonts
5257 if : matrix.os == 'windows-2022' || matrix.os == 'windows-2019'
5358 run : Copy-Item -Path "tessdata_unittest\fonts\*" -Destination "test\testing" -Recurse
5459 shell : pwsh
5560
5661 - name : test
57- if : matrix.os != 'windows-2022' && matrix.os != 'windows-2019'
62+ if : github.event_name != 'pull_request' && ( matrix.os != 'windows-2022' && matrix.os != 'windows-2019')
5863 run : ./sw -static -shared -config "d,r" test -Dwith-tests=1 "-Dskip-tests=lstm,lstm_recode"
5964 continue-on-error : true
65+ - name : test
66+ if : github.event_name == 'pull_request' && (matrix.os != 'windows-2022' && matrix.os != 'windows-2019')
67+ run : ./sw test -Dwith-tests=1 "-Dskip-tests=lstm,lstm_recode"
68+ continue-on-error : true
6069
6170 - name : test-nightly
6271 if : matrix.os != 'windows-2022' && matrix.os != 'windows-2019' && matrix.os != 'macos-12' && github.event.schedule=='0 0 * * *'
0 commit comments