Skip to content

Commit 10b9ba4

Browse files
authored
Merge pull request #56 from thewtex/archive-windows
Fix OS archive command
2 parents 092eed3 + 5b244e8 commit 10b9ba4

File tree

1 file changed

+13
-9
lines changed

1 file changed

+13
-9
lines changed

.github/workflows/ci.yml

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -42,18 +42,22 @@ jobs:
4242
cd build/castxml-prefix/src/castxml-build
4343
ctest --output-on-failure
4444
45-
- name: Archive
45+
- name: Create archive for Windows
46+
if: matrix.os == 'windows-2022'
4647
shell: cmd
4748
run: |
4849
cd build
49-
if [[ "${{ runner.os }}" == "Windows" ]]; then
50-
7z a castxml-windows.zip castxml
51-
mv castxml-windows.zip ..
52-
else
53-
tar cvf castxml-${{ matrix.os }}.tar castxml
54-
gzip -9 castxml-${{ matrix.os }}.tar
55-
mv castxml-${{ matrix.os }}.tar.gz ..
56-
fi
50+
7z a castxml-windows.zip castxml
51+
move castxml-windows.zip ..
52+
53+
- name: Create archive for macOS and Ubuntu
54+
if: matrix.os != 'windows-2022'
55+
shell: bash
56+
run: |
57+
cd build
58+
tar cvf castxml-${{ matrix.os }}.tar castxml
59+
gzip -9 castxml-${{ matrix.os }}.tar
60+
mv castxml-${{ matrix.os }}.tar.gz ..
5761
5862
- name: Upload artifact
5963
uses: actions/upload-artifact@v4

0 commit comments

Comments
 (0)