From 822d6ec88e0774e23fae8e7ca31c07b35c450057 Mon Sep 17 00:00:00 2001 From: Aikawa Yataro Date: Sat, 3 Aug 2024 13:50:57 +0000 Subject: [PATCH] ci: tar artifact to keep permissions --- .github/workflows/ci.yml | 6 ++++++ .github/workflows/package.yml | 7 +++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3a12b9e1..87d460c6 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -60,6 +60,12 @@ jobs: - name: Rename executable file if: ${{ startsWith(matrix.runtime, 'linux-') }} run: mv publish/SourceGit publish/sourcegit + - name: Tar artifact + if: ${{ startsWith(matrix.runtime, 'linux-') }} + run: | + tar -cvf "sourcegit.${{ matrix.runtime }}.tar" -C publish . + rm -r publish/* + mv "sourcegit.${{ matrix.runtime }}.tar" publish - name: Upload artifact uses: actions/upload-artifact@v4 with: diff --git a/.github/workflows/package.yml b/.github/workflows/package.yml index 8ffcf88e..404c909e 100644 --- a/.github/workflows/package.yml +++ b/.github/workflows/package.yml @@ -79,12 +79,15 @@ jobs: uses: actions/download-artifact@v4 with: name: sourcegit.${{ matrix.runtime }} - path: build/SourceGit + path: build - name: Package env: VERSION: ${{ inputs.version }} RUNTIME: ${{ matrix.runtime }} - run: ./build/ci/package.linux.sh + run: | + mkdir build/SourceGit + tar -xf "build/sourcegit.${{ matrix.runtime }}.tar" -C build/SourceGit + ./build/ci/package.linux.sh - name: Upload package artifacts uses: actions/upload-artifact@v4 with: