forked from bilibili/ijkplayer
-
Notifications
You must be signed in to change notification settings - Fork 93
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #46 from befovy/develop
ci: add android ios release ci
- Loading branch information
Showing
6 changed files
with
109 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
name: Android Release | ||
|
||
on: | ||
push: | ||
tags: | ||
- 'f*' | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: set up JDK 1.8 | ||
uses: actions/setup-java@v1 | ||
with: | ||
java-version: 1.8 | ||
|
||
- name: Setup ndk | ||
run: | | ||
yes 2>/dev/null | sudo $ANDROID_HOME/tools/bin/sdkmanager --install "ndk;16.1.4479499" "cmake;3.10.2.4988404" | ||
- name: Init extra for android | ||
run: | | ||
export ANDROID_NDK=$ANDROID_HOME/ndk/16.1.4479499/ | ||
bash init-android.sh | ||
bash init/init-android-boringssl.sh | ||
bash init/init-android-libsrt.sh | ||
- name: Build ssl and ffmpeg | ||
run: | | ||
cd android/contrib | ||
export ANDROID_NDK=$ANDROID_HOME/ndk/16.1.4479499/ | ||
bash compile-boringssl.sh all | ||
wget --no-check-certificate https://raw.githubusercontent.com/FFmpeg/gas-preprocessor/master/gas-preprocessor.pl | ||
chmod +x gas-preprocessor.pl && sudo mv gas-preprocessor.pl /usr/local/bin/ | ||
bash compile-ffmpeg.sh all | ||
- name: Gradle build and publish | ||
working-directory: android/ijkplayer | ||
env: | ||
BINTRAY_USER: befovy | ||
BINTRAY_APIKEY: ${{ secrets.BINTRAY_APIKEY }} | ||
run: | | ||
export ANDROID_NDK=$ANDROID_HOME/ndk/16.1.4479499/ | ||
./gradlew build | ||
./gradlew bintrayUpload |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
name: iOS Release | ||
|
||
on: | ||
push: | ||
tags: | ||
- 'f*' | ||
|
||
jobs: | ||
build: | ||
runs-on: macos-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Init extra for iOS | ||
run: | | ||
bash init-ios-openssl.sh | ||
bash init-ios.sh | ||
- name: Build ssl and ffmpeg | ||
working-directory: ios | ||
run: | | ||
bash compile-openssl.sh all | ||
bash compile-ffmpeg.sh all | ||
- name: XCode build ijkplayer | ||
working-directory: ios/IJKMediaPlayer | ||
run: xcodebuild -project IJKMediaPlayer.xcodeproj -configuration Release -scheme Universal | ||
|
||
- name: Create Release | ||
id: create_release | ||
uses: actions/create-release@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
tag_name: ${{ github.ref }} | ||
release_name: Release ${{ github.ref }} | ||
draft: false | ||
prerelease: false | ||
|
||
- name: Upload iOS Framework | ||
uses: actions/upload-release-asset@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
upload_url: ${{ steps.create_release.outputs.upload_url }} | ||
asset_path: ./ios/CocoaPodsPub/IJKMediaPlayer.tar.gz | ||
asset_name: IJKMediaPlayer.tar.gz | ||
asset_content_type: application/gzip |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters