From 569a9a5629da6be1acc93fca71418459a962f441 Mon Sep 17 00:00:00 2001 From: fgnm Date: Sat, 21 May 2022 19:58:03 +0200 Subject: [PATCH] [editor only] Add build info too --- .github/workflows/snapshot.yml | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/.github/workflows/snapshot.yml b/.github/workflows/snapshot.yml index bad123c6..3685f81b 100644 --- a/.github/workflows/snapshot.yml +++ b/.github/workflows/snapshot.yml @@ -38,7 +38,7 @@ jobs: with: name: Linux.HyperLap2D-SNAPSHOT.deb path: Linux.HyperLap2D-SNAPSHOT.deb - - name: Sync files with server + - name: Sync files with production server uses: garygrossgarten/github-action-scp@release with: host: ${{ secrets.DEPLOY_SSH_HOST }} @@ -47,6 +47,20 @@ jobs: port: ${{ secrets.DEPLOY_SSH_PORT }} local: "Linux.HyperLap2D-SNAPSHOT.deb" remote: ${{ format('{0}/{1}', secrets.DEPLOY_SSH_TARGET_PATH, 'Linux.HyperLap2D-SNAPSHOT.deb') }} + - name: Generate build info + env: + WORKFLOW_RUN: ${{ github.run_number }} + run: | + echo "{ \"build\": $WORKFLOW_RUN }" > snapshot.json + - name: Sync build info with production server + uses: garygrossgarten/github-action-scp@release + with: + host: ${{ secrets.DEPLOY_SSH_HOST }} + username: ${{ secrets.DEPLOY_SSH_USERNAME }} + password: ${{ secrets.DEPLOY_SSH_PASSWORD }} + port: ${{ secrets.DEPLOY_SSH_PORT }} + local: "snapshot.json" + remote: ${{ format('{0}/{1}', secrets.DEPLOY_SSH_TARGET_PATH, 'snapshot.json') }} - name: Publish SNAPSHOT artifacts if: "!contains(github.event.head_commit.message, 'editor only')" env: