Skip to content

Commit

Permalink
jj
Browse files Browse the repository at this point in the history
  • Loading branch information
ed-asriyan committed Oct 18, 2023
1 parent c78c6ea commit 7ef38f8
Show file tree
Hide file tree
Showing 2 changed files with 64 additions and 5 deletions.
67 changes: 63 additions & 4 deletions .github/workflows/ci-build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -184,19 +184,60 @@ jobs:
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: lottie-to-png.win.amd64
path: .
name: lottie-to-png.win.amd64.exe
path: bin/Release/lottie_to_png.exe

- name: Upload test results as artifacts
uses: actions/upload-artifact@v3
with:
name: test-results.windows.amd64.${{ matrix.case }}
path: test-files

release:
test-windows:
name: Test Windows
needs: build-windows
runs-on: windows-latest
strategy:
matrix:
case:
- apng
- gif
- png
- webp
steps:
- uses: actions/checkout@v3

- name: Install run-time dependencies
run: |
[[ "${{ matrix.case }}" == "apng" ]] && winget install ffmpeg || echo ok;
[[ "${{ matrix.case }}" == "gif" ]] && cargo install gifski || echo ok;
[[ "${{ matrix.case }}" == "webp" ]] && brew install webp || echo ok;
- name: Download artifact
uses: actions/download-artifact@v3
with:
name: lottie-to-png.windows.amd64.exe
path: bin

- name: Run tests
run: |
chmod +x bin/lottie_to_png && \
bash -c "\
find test-files -type f \( -iname \*.json -o -iname \*.lottie -o -iname \*.tgs \) | while IFS=$'\n' read -r FILE; do \
echo Converting \${FILE}... && sh ./bin/lottie_to_${{ matrix.case }}.sh \$FILE && echo Done.; \
done \
"
- name: Upload test results as artifacts
uses: actions/upload-artifact@v3
with:
name: test-results.windows.amd64.${{ matrix.case }}
path: test-files

release-linux:
name: Release linux executables
needs:
- test-docker
- test-darwin
runs-on: ubuntu-latest
strategy:
matrix:
Expand Down Expand Up @@ -231,3 +272,21 @@ jobs:
name: ${{ github.ref }}
allowUpdates: true
draft: true

release-darwin:
name: Release darwin executables
needs:
- test-darwin
runs-on: ubuntu-latest
steps:
- name: Extract
run: echo stub

release-windows:
name: Release windows executables
needs:
- test-windows
runs-on: ubuntu-latest
steps:
- name: Extract
run: echo stub
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ Results will be saved next to each source file in the same directory.
```
2. Build
```commandline
cmake -DCMAKE_BUILD_TYPE=Release CMakeLists.txt && cmake --build .
cmake -DCMAKE_BUILD_TYPE=Release CMakeLists.txt && cmake --build . --config Release
```
<details>
<summary>M1 troubleshooting</summary>
Expand Down

0 comments on commit 7ef38f8

Please sign in to comment.