Skip to content

Commit

Permalink
[#2185] Create workflow for publishing release (#2186)
Browse files Browse the repository at this point in the history
* [#2185] Create workflow for publishing release

* [#2185] Create workflow for publishing release
  • Loading branch information
mustafaozhan authored Mar 15, 2023
1 parent 63e0127 commit 1130017
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 17 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ jobs:
groups: QA
file: huawei/release/app-huawei-release.apk

- name: Delete Google APK
- name: Delete Android Artifacts
uses: geekyeggo/delete-artifact@v2
with:
name: androidArtifacts
Expand Down
39 changes: 39 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Publish Release

on:
push:
tags:
- "v*"

jobs:

PublishRelease:
runs-on: ubuntu-latest
outputs:
status: ${{ steps.status.outputs.status }}
steps:

- name: PublishRelease
uses: marvinpinto/[email protected]
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}

- name: Set Job Status
id: status
run: echo "::set-output name=status::success"

Notify:
runs-on: ubuntu-latest
needs: [ PublishRelease ]
if: always()
steps:

- name: Notify slack fail
if: false == (needs.PublishRelease.outputs.status == 'success')
uses: voxmedia/github-action-slack-notify-build@v2
env:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
with:
channel: ccc-github
status: FAILED
color: danger
16 changes: 0 additions & 16 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -250,22 +250,6 @@ jobs:
id: status
run: echo "::set-output name=status::success"

PublishRelease:
runs-on: ubuntu-latest
needs: [ GenerateGradleArtifacts, UploadToGooglePlay, UploadToHuaweiAppGallery, DeployToServer, UploadToAppStore ]
outputs:
status: ${{ steps.status.outputs.status }}
steps:

- name: PublishRelease
uses: marvinpinto/[email protected]
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}

- name: Set Job Status
id: status
run: echo "::set-output name=status::success"

Notify:
runs-on: ubuntu-latest
needs: [ GenerateGradleArtifacts, UploadToGooglePlay, UploadToHuaweiAppGallery, DeployToServer, UploadToAppStore ]
Expand Down

0 comments on commit 1130017

Please sign in to comment.