From f8e08605a52edb2fc650d4c16a34acd4808949cc Mon Sep 17 00:00:00 2001 From: Pranav C Date: Mon, 20 Jun 2022 11:41:00 +0530 Subject: [PATCH] chore: integrate with nightly-dev and pr release actions Signed-off-by: Pranav C --- .github/workflows/release-nightly-dev.yml | 9 ++++++++- .github/workflows/release-pr.yml | 24 ++++++++++++++++++++--- 2 files changed, 29 insertions(+), 4 deletions(-) diff --git a/.github/workflows/release-nightly-dev.yml b/.github/workflows/release-nightly-dev.yml index af71aa58ff..c05a477da1 100644 --- a/.github/workflows/release-nightly-dev.yml +++ b/.github/workflows/release-nightly-dev.yml @@ -37,7 +37,7 @@ jobs: outputs: nightly_build_tag: ${{ steps.tag-step.outputs.NIGHTLY_BUILD_TAG }} is_daily: ${{ steps.tag-step.outputs.IS_DAILY }} - current_version: ${{ steps.tag-step.outputs.CURRENT_VERSION }} + current_version: ${{ steps.tag-step.outputs.CURRENT_VERSION }} # Build frontend and backend and publish to npm release-npm: needs: set-tag @@ -48,6 +48,13 @@ jobs: secrets: NPM_TOKEN: "${{ secrets.NPM_TOKEN }}" + # Build executables and publish to GitHub + release-executables: + needs: [set-tag, release-npm] + uses: ./.github/workflows/release-executables.yml + with: + tag: ${{ needs.set-tag.outputs.nightly_build_tag }} + # Build docker image and push to docker hub release-docker: needs: [set-tag, release-npm] diff --git a/.github/workflows/release-pr.yml b/.github/workflows/release-pr.yml index 38cce2c390..394bd8b1ab 100644 --- a/.github/workflows/release-pr.yml +++ b/.github/workflows/release-pr.yml @@ -50,7 +50,7 @@ jobs: echo ${{ steps.tag-step.outputs.CURRENT_VERSION }} outputs: target_tag: ${{ steps.tag-step.outputs.TARGET_TAG }} - current_version: ${{ steps.tag-step.outputs.CURRENT_VERSION }} + current_version: ${{ steps.tag-step.outputs.CURRENT_VERSION }} # Build, install, publish frontend and backend to npm release-npm: @@ -77,13 +77,21 @@ jobs: DOCKERHUB_USERNAME: "${{ secrets.DOCKERHUB_USERNAME }}" DOCKERHUB_TOKEN: "${{ secrets.DOCKERHUB_TOKEN }}" + # Build executables and publish to GitHub + release-executables: + needs: [set-tag, release-npm] + uses: ./.github/workflows/release-executables.yml + with: + tag: ${{ needs.set-tag.outputs.target_tag }} + current-version: ${{ needs.set-tag.outputs.current_version }} + # leave-comment: # runs-on: 'ubuntu-latest' # needs: [release-docker, set-tag] # steps: # - run: | # echo docker run -d -p 8888:8080 nocodb/nocodb-timely:${{ needs.set-tag.outputs.current_version }}-${{ needs.set-tag.outputs.target_tag }} - + leave-comment: if: ${{ github.actor != 'dependabot[bot]' && github.event.pull_request.draft == false }} runs-on: 'ubuntu-latest' @@ -96,7 +104,17 @@ jobs: ``` docker run -d -p 8888:8080 nocodb/nocodb-timely:${{ needs.set-tag.outputs.current_version }}-${{ needs.set-tag.outputs.target_tag }} ``` - + + leave-executable-comment: + if: ${{ github.actor != 'dependabot[bot]' && github.event.pull_request.draft == false }} + runs-on: 'ubuntu-latest' + needs: [release-executables] + steps: + - uses: peter-evans/commit-comment@v2 + with: + body: | + The PR changes have been deployed as executables. Pleae visit following link to download executables : https://github.com/nocodb/nocodb-timely/releases/tag/${{ needs.set-tag.outputs.target_tag }} + # if-merged: # if: github.event.pull_request.merged == true # runs-on: ubuntu-latest