Skip to content

Commit

Permalink
Update android-ci.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
Sheikh-Abdul-Aziz authored Aug 1, 2024
1 parent ff59f9d commit 62c972a
Showing 1 changed file with 38 additions and 38 deletions.
76 changes: 38 additions & 38 deletions .github/workflows/android-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,41 +75,41 @@ jobs:
echo "Build log file not found."
fi
release:
needs: build
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')

steps:
# Step 1: Check out the repository
- uses: actions/checkout@v3

# Step 2: Download the Release APK
- name: Download Release APK
uses: actions/download-artifact@v2
with:
name: app-release
path: .

# Step 3: Create GitHub Release
- name: Create GitHub Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref_name }}
release_name: Release ${{ github.ref_name }}
draft: false
prerelease: false

# Step 4: Upload APK to Release
- name: Upload APK to Release
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./app-release.apk
asset_name: app-release.apk
asset_content_type: application/vnd.android.package-archive
release:
needs: build
runs-on: ubuntu-latest
if: github.event_name == 'release' && startsWith(github.ref, 'refs/tags/')

steps:
# Step 1: Check out the repository
- uses: actions/checkout@v3

# Step 2: Download the Release APK
- name: Download Release APK
uses: actions/download-artifact@v2
with:
name: app-release
path: .

# Step 3: Create GitHub Release
- name: Create GitHub Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref_name }}
release_name: Release ${{ github.ref_name }}
draft: false
prerelease: false

# Step 4: Upload APK to Release
- name: Upload APK to Release
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./app-release.apk
asset_name: app-release.apk
asset_content_type: application/vnd.android.package-archive

0 comments on commit 62c972a

Please sign in to comment.