fix: renaming of files

This commit is contained in:
PandaDEV 2024-11-24 15:17:39 +10:00
parent ff5081308c
commit 89b67f24f2
No known key found for this signature in database
GPG key ID: 13EFF9BAF70EE75C

View file

@ -133,10 +133,32 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with: with:
args: ${{ matrix.args }} args: ${{ matrix.args }}
- name: List Bundle Directory
- name: Rename Windows Artifacts shell: pwsh
run: | run: |
mv src-tauri/target/release/bundle/msi/*.msi src-tauri/target/release/bundle/msi/Qopy-${{ needs.prepare.outputs.version }}_${{ matrix.arch }}.msi $bundlePath = "src-tauri/target/release/bundle/msi"
if (Test-Path $bundlePath) {
Write-Output "Contents of $bundlePath:"
Get-ChildItem -Path $bundlePath
} else {
Write-Output "Path $bundlePath does not exist."
}
- name: Rename Windows Artifacts
shell: pwsh
run: |
$bundlePath = "src-tauri/target/release/bundle/msi"
$version = "${{ needs.prepare.outputs.version }}"
$arch = "${{ matrix.arch }}"
if (Test-Path $bundlePath) {
$msiFiles = Get-ChildItem -Path "$bundlePath/*.msi"
foreach ($file in $msiFiles) {
$newName = "Qopy-$version`_$arch.msi"
Rename-Item -Path $file.FullName -NewName $newName
}
} else {
Write-Error "Path $bundlePath does not exist."
exit 1
}
- name: Upload artifacts - name: Upload artifacts
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with: