From cd7b2b8deb1913289c06027b0ed28dfb69bda944 Mon Sep 17 00:00:00 2001 From: amass <168062547@qq.com> Date: Sun, 30 Jun 2024 18:04:21 +0800 Subject: [PATCH] test env. --- .gitea/workflows/deploy.yaml | 10 ++++------ resources/notify.tpl | 6 ------ 2 files changed, 4 insertions(+), 12 deletions(-) delete mode 100644 resources/notify.tpl diff --git a/.gitea/workflows/deploy.yaml b/.gitea/workflows/deploy.yaml index 5db26b3..edd5905 100644 --- a/.gitea/workflows/deploy.yaml +++ b/.gitea/workflows/deploy.yaml @@ -14,11 +14,9 @@ jobs: - name: Send success notification if: ${{ always() }} run: | - echo "repo: ${{ github.repository }}" >> notify.tpl - echo "actor:${{ github.actor }}" >> notify.tpl - echo "status: ${{ job.status }}">> notify.tpl - echo "commit: ${{ github.sha }}">> notify.tpl + echo "repo: ${{ github.repository }}" >> notify.tpl + echo "status: ${{ job.status }}">> notify.tpl + echo "commit: $(git rev-parse --short HEAD)">> notify.tpl echo "message: ${{ github.event.head_commit.message }}">> notify.tpl - echo "仓库地址: ${{ github.repositoryUrl }}">> notify.tpl - cat notify.tpl | envsubst | jq -sR . + echo "repo link: https://gitea.amass.fun/${{ github.repositoryUrl }}">> notify.tpl cat notify.tpl | envsubst | jq -sR . | xargs -0 -I {} curl -H "Content-Type: application/json" -X POST -d '{"type":"text","msg":{} }' https://amass.fun/notify \ No newline at end of file diff --git a/resources/notify.tpl b/resources/notify.tpl deleted file mode 100644 index e6089ab..0000000 --- a/resources/notify.tpl +++ /dev/null @@ -1,6 +0,0 @@ -repo: $AMASS_GITEA_REPO_NAME -status: $AMASS_GITEA_BUILD_STATUS -commit: $AMASS_GITEA_COMMIT -message: $AMASS_GITEA_COMMIT_MESSAGE -build link: $AMASS_GITEA_BUILD_LINK -repo link: $AMASS_GITEA_REPO_LINK \ No newline at end of file