Skip to content

Commit

Permalink
Update android.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaowine authored Feb 14, 2024
1 parent 7c32bfc commit 06b7bef
Showing 1 changed file with 0 additions and 16 deletions.
16 changes: 0 additions & 16 deletions .github/workflows/android.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,19 +79,3 @@ jobs:
with:
name: Lyric Getter mapping
path: ./app/build/outputs/mapping/release/mapping.txt

- name: Post to channel
if: contains(github.event.head_commit.message, '[skip post]') == false && github.event_name != 'pull_request'
env:
CHANNEL_ID: ${{ secrets.CHANNEL_DEV_ID }}
BOT_TOKEN: ${{ secrets.BOT_DEV_TOKEN }}
COMMIT_MESSAGE: |+
Github CI
```
${{ github.event.head_commit.message }}
```
run: |
export RELEASE=$(find ./app/build/outputs/apk/release -name "*.apk")
export DEBUG=$(find ./app/build/outputs/apk/debug -name "*.apk")
ESCAPED=`python3 -c 'import json,os,urllib.parse; print(urllib.parse.quote(json.dumps(os.environ["COMMIT_MESSAGE"])))'`
curl -v "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%2Frelease%22%7D%2C%7B%22type%22%3A%22document%22%2C%20%22media%22%3A%22attach%3A%2F%2Fdebug%22%2C%22parse_mode%22%3A%22MarkdownV2%22%2C%22caption%22%3A${ESCAPED}%7D%5D" -F release="@$RELEASE" -F debug="@$DEBUG"

0 comments on commit 06b7bef

Please sign in to comment.