Skip to content

Commit 264b6dd

Browse files
Pipeline: add steps to delete previous artifacts to prevent caching issues (#337)
1 parent d8ac2f3 commit 264b6dd

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed

.github/workflows/build-and-release.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -294,6 +294,35 @@ jobs:
294294
} else {
295295
Write-Output "Tauri is already installed"
296296
}
297+
298+
- name: Delete previous artifact, which may exist due to caching (macOS)
299+
if: startsWith(matrix.platform, 'macos')
300+
run: |
301+
rm -f runtime/target/${{ matrix.rust_target }}/release/bundle/dmg/MindWork AI Studio_*.dmg
302+
rm -f runtime/target/${{ matrix.rust_target }}/release/bundle/macos/MindWork AI Studio.app.tar.gz*
303+
304+
- name: Delete previous artifact, which may exist due to caching (Windows - MSI)
305+
if: startsWith(matrix.platform, 'windows') && contains(matrix.tauri_bundle, 'msi')
306+
run: |
307+
rm -f runtime/target/${{ matrix.rust_target }}/release/bundle/msi/MindWork AI Studio_*.msi
308+
rm -f runtime/target/${{ matrix.rust_target }}/release/bundle/msi/MindWork AI Studio*msi.zip*
309+
310+
- name: Delete previous artifact, which may exist due to caching (Windows - NSIS)
311+
if: startsWith(matrix.platform, 'windows') && contains(matrix.tauri_bundle, 'nsis')
312+
run: |
313+
rm -f runtime/target/${{ matrix.rust_target }}/release/bundle/nsis/MindWork AI Studio_*.exe
314+
rm -f runtime/target/${{ matrix.rust_target }}/release/bundle/nsis/MindWork AI Studio*nsis.zip*
315+
316+
- name: Delete previous artifact, which may exist due to caching (Linux - Debian Package)
317+
if: startsWith(matrix.platform, 'ubuntu') && contains(matrix.tauri_bundle, 'deb')
318+
run: |
319+
rm -f runtime/target/${{ matrix.rust_target }}/release/bundle/deb/mind-work-ai-studio_*.deb
320+
321+
- name: Delete previous artifact, which may exist due to caching (Linux - AppImage)
322+
if: startsWith(matrix.platform, 'ubuntu') && contains(matrix.tauri_bundle, 'appimage')
323+
run: |
324+
rm -f runtime/target/${{ matrix.rust_target }}/release/bundle/appimage/mind-work-ai-studio_*.AppImage
325+
rm -f runtime/target/${{ matrix.rust_target }}/release/bundle/appimage/mind-work-ai-studio*AppImage.tar.gz*
297326
298327
- name: Build Tauri project (Unix)
299328
if: matrix.platform != 'windows-latest'
@@ -509,6 +538,11 @@ jobs:
509538
if: ${{ steps.linux_arm_cache.outputs.cache-hit != 'true' && env.SKIP != 'true' }}
510539
run: |
511540
mv ${{ steps.build-linux-arm-runner.outputs.image }} ${{ runner.temp }}/linux_arm_qemu_cache.img
541+
542+
- name: Delete previous artifact, which may exist due to caching (Linux - Debian Package)
543+
if: ${{ env.SKIP != 'true' }}
544+
run: |
545+
rm -f result/target/aarch64-unknown-linux-gnu/release/bundle/deb/mind-work-ai-studio_*.deb
512546
513547
- name: Build Tauri project
514548
if: ${{ env.SKIP != 'true' }}

0 commit comments

Comments
 (0)