From 60ef06ac51c8e5fab1c4d19f14d95f3f004a4333 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Mon, 23 Jan 2023 09:44:51 +0100 Subject: Merging upstream version 1.7.3. Signed-off-by: Daniel Baumann --- .github/workflows/release.yml | 79 ++++++++++++------------------------------- 1 file changed, 22 insertions(+), 57 deletions(-) (limited to '.github/workflows/release.yml') diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a0ea6bf..9500cee 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -6,30 +6,14 @@ on: - "*" jobs: - release: - runs-on: ubuntu-20.04 - outputs: - upload_url: ${{ steps.create_release.outputs.upload_url }} - steps: - - name: Create Release - id: create_release - uses: actions/create-release@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - tag_name: ${{ github.ref }} - release_name: ${{ github.ref }} - draft: true - prerelease: false - build: runs-on: ubuntu-20.04 - needs: release strategy: + fail-fast: false matrix: - target: [i686, x86_64, arm, armhf, aarch64, mips, mipsel, mips64, mips64el, s390x] + target: [i686, x86_64, arm, armhf, aarch64, mips, mipsel, mips64, mips64el, s390x, win32] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Install packages run: | sudo apt-get update @@ -38,44 +22,25 @@ jobs: env: BUILD_TARGET: ${{ matrix.target }} run: ./scripts/cross-build.sh - - name: Upload assets - id: upload-release-asset - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + - uses: actions/upload-artifact@v3 with: - upload_url: ${{ needs.release.outputs.upload_url }} - asset_path: build/ttyd - asset_name: ttyd.${{ matrix.target }} - asset_content_type: application/octet-stream - win10: - runs-on: windows-latest - needs: release + name: ttyd.${{ matrix.target }} + path: build/ttyd* + publish: + needs: [build] + runs-on: ubuntu-20.04 steps: - - uses: actions/checkout@v2 - - uses: msys2/setup-msys2@v2 + - uses: actions/checkout@v3 + - uses: actions/download-artifact@v3 + - run: | + mkdir build + for file in ttyd.*/*; do + target=$(echo $file | awk -F/ '{print $1}') + [[ $file == *.exe ]] && target="$target.exe" + mv $file build/$target + done + - uses: ncipollo/release-action@v1 with: - msystem: MINGW64 - install: >- - base-devel - subversion - mingw64/mingw-w64-x86_64-gcc - mingw64/mingw-w64-x86_64-cmake - mingw64/mingw-w64-x86_64-zlib - mingw64/mingw-w64-x86_64-libuv - mingw64/mingw-w64-x86_64-mbedtls - mingw64/mingw-w64-x86_64-json-c - update: true - - name: Build ttyd - shell: msys2 {0} - run: ./scripts/mingw-build.sh - - name: Upload assets - id: upload-release-asset - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ needs.release.outputs.upload_url }} - asset_path: build/ttyd.exe - asset_name: ttyd.win10.exe - asset_content_type: application/octet-stream + artifacts: build/* + allowUpdates: true + draft: true -- cgit v1.2.3