Skip to content

Commit c22911e

Browse files
committed
update workflows
Signed-off-by: Dev4Mod <[email protected]>
1 parent 424ed2b commit c22911e

File tree

2 files changed

+12
-6
lines changed

2 files changed

+12
-6
lines changed

.github/workflows/android.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ jobs:
77
build:
88
permissions: write-all
99
runs-on: ubuntu-latest
10-
if: github.event_name == 'push'
10+
if: github.event_name == 'push' && !contains(github.event.head_commit.message, 'Merge')
1111
steps:
1212
- uses: actions/checkout@v4
1313
- name: set up JDK 17
@@ -58,11 +58,14 @@ jobs:
5858
curl "https://api.telegram.org/bot${BOT_TOKEN}/sendMediaGroup?chat_id=${CHANNEL_ID}&media=%5B%7B%22type%22%3A%22document%22%2C%20%22media%22%3A%22attach%3A%2F%2Foutput%22%2C%22caption%22:${ESCAPED}%7D%5D" -F output="@$output"
5959
fi
6060
61+
- name: Add SHORT_SHA env property with commit short sha
62+
run: echo "SHORT_SHA=`echo ${GITHUB_SHA} | cut -c1-8`" >> $GITHUB_ENV
63+
6164
- name: Upload to release
6265
uses: softprops/action-gh-release@v2
6366
with:
6467
token: ${{ secrets.GITHUB_TOKEN }}
65-
name: WaEnhancer ${{ github.sha }}
68+
name: WaEnhancer ${{ env.SHORT_SHA }}
6669
body_path: changelog.txt
6770
files: app/build/outputs/apk/debug/app-debug.apk
68-
tag_name: pre-release-${{ github.sha }}
71+
tag_name: pre-release-${{ env.SHORT_SHA }}

.github/workflows/business.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ jobs:
77
build:
88
permissions: write-all
99
runs-on: ubuntu-latest
10-
if: github.event_name == 'push'
10+
if: github.event_name == 'push' && !contains(github.event.head_commit.message, 'Merge')
1111
steps:
1212
- uses: actions/checkout@v4
1313
- name: set up JDK 17
@@ -49,11 +49,14 @@ jobs:
4949
name: Wa Enhancer ${{ steps.version.outputs.builddate }}
5050
path: app/build/outputs/apk/debug/app-debug.apk
5151

52+
- name: Add SHORT_SHA env property with commit short sha
53+
run: echo "SHORT_SHA=`echo ${GITHUB_SHA} | cut -c1-8`" >> $GITHUB_ENV
54+
5255
- name: Upload to release
5356
uses: softprops/action-gh-release@v2
5457
with:
5558
token: ${{ secrets.GITHUB_TOKEN }}
56-
name: WaEnhancer Business ${{ github.sha }}
59+
name: WaEnhancer Business ${{ env.SHORT_SHA }}
5760
body_path: changelog.txt
5861
files: app/build/outputs/apk/debug/app-debug.apk
59-
tag_name: pre-release-business-${{ github.sha }}
62+
tag_name: pre-release-business-${{ env.SHORT_SHA }}

0 commit comments

Comments
 (0)