Skip to content

Commit

Permalink
複数エンジン対応:vvppファイルのビルドを追加 (#524)
Browse files Browse the repository at this point in the history
* Add: vvppファイルのビルドを追加

* Fix: 番号を修正

* Fix: txtをアップロードするように

* Fix: 引数を修正

* Fix: ファイル名を修正

* Change: 001だけの時は番号を振らないように

* Fix: 異常終了を無視するように

* Fix: パターンを修正

* Change: 細かい部分を変更
  • Loading branch information
sevenc-nanashi authored Dec 10, 2022
1 parent a6fff78 commit b28601b
Showing 1 changed file with 17 additions and 4 deletions.
21 changes: 17 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -528,12 +528,23 @@ jobs:

- name: Rearchive and split artifact
run: |
# compressed to artifact.7z.001, artifact.7z.002, ...
7z -r -v1g a "${{ matrix.artifact_name }}.7z" "${{ matrix.artifact_name }}/"
# Compress to artifact.7z.001, artifact.7z.002, ...
7z -r -v2g a "${{ matrix.artifact_name }}.7z" "${{ matrix.artifact_name }}/"
# Compress to artifact.001.vvpp,artifact.002.vvpp, ...
(cd "${{ matrix.artifact_name }}" && zip -r - . > ../compressed.zip)
split -b 2G --numeric-suffixes=1 -a 3 --additional-suffix .vvpp ./compressed.zip ./${{ matrix.artifact_name }}.
# Rename to artifact.vvpp if there are only artifact.001.vvpp
if [ "$(ls ${{ matrix.artifact_name }}.*.vvpp | wc -l)" == 1 ]; then
mv ${{ matrix.artifact_name }}.001.vvpp ${{ matrix.artifact_name }}.vvpp
fi
# Output splitted archive list
ls ${{ matrix.artifact_name }}.7z.* > archives.txt
mv archives.txt "${{ matrix.artifact_name }}.7z.txt"
ls ${{ matrix.artifact_name }}.7z.* > archives_7z.txt
mv archives_7z.txt "${{ matrix.artifact_name }}.7z.txt"
ls ${{ matrix.artifact_name }}*.vvpp > archives_vvpp.txt
mv archives_vvpp.txt "${{ matrix.artifact_name }}.vvpp.txt"
- name: Upload splitted archives to Release assets
uses: softprops/action-gh-release@v1
Expand All @@ -542,6 +553,8 @@ jobs:
tag_name: ${{ env.VOICEVOX_ENGINE_VERSION }}
files: |-
${{ matrix.artifact_name }}.7z.*
${{ matrix.artifact_name }}*.vvpp
${{ matrix.artifact_name }}.vvpp.txt
target_commitish: ${{ github.sha }}

run-release-test-workflow:
Expand Down

0 comments on commit b28601b

Please sign in to comment.