升级 Gradle 和依赖版本,优化音频通话逻辑 #121
Workflow file for this run
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
name: NLiteAVDemo - Android | |
on: | |
push: | |
branches: [ master, develop, feature/feature_Android ] | |
pull_request: | |
branches: [ master ] | |
jobs: | |
build_video_stream_java: | |
name: Build NEChatroom Java | |
runs-on: windows-latest | |
env: | |
CONFIG_FILE_PATH: ${{ './baselib/src/main/cpp/config.cpp' }} | |
CONFIG_STUB_SCRIPT_PATH: ${{ './workflow/config_stub.py' }} | |
ENCRYPTED_KEYSTORE_PATH: ${{ './workflow/release.jks.gpg' }} | |
DECRYPTED_KEYSTORE_PATH: ${{ './workflow/release.jks' }} | |
UNSIGNED_APK_PATH: ${{ './app/build/outputs/apk/release/app-release-unsigned.apk' }} | |
SIGNED_APK_PATH: ${{ './app/build/outputs/apk/release/NEVideoCall-Android-Java.apk' }} | |
APP_KEY: ${{ secrets.APP_KEY }} | |
BASE_URL: ${{ secrets.API_BASE_URL }} | |
KEYSTORE_ENC_PWD: ${{ secrets.KEYSTORE_ENC_PWD }} | |
defaults: | |
run: | |
shell: bash | |
working-directory: ./NLiteAVDemo-Android-Java/ | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up JDK 1.8 | |
uses: actions/setup-java@v1 | |
with: | |
java-version: 1.8 | |
- name: Setup Python 3.12.4 | |
uses: actions/setup-python@v2 | |
with: | |
python-version: '3.12.4' | |
- name: Config Stub | |
run: | |
python $CONFIG_STUB_SCRIPT_PATH $CONFIG_FILE_PATH $APP_KEY $BASE_URL | |
- name: Configure Keystore | |
run: | |
gpg -d -o "$DECRYPTED_KEYSTORE_PATH" --pinentry-mode=loopback --passphrase "$KEYSTORE_ENC_PWD" "$ENCRYPTED_KEYSTORE_PATH" | |
- name: Build APK | |
run: | |
./gradlew assembleRelease | |
- name: Sign APK | |
run: | |
/C/'Program Files (x86)'/Android/android-sdk/build-tools/29.0.3/apksigner.bat sign --ks $DECRYPTED_KEYSTORE_PATH --ks-pass pass:$KEYSTORE_ENC_PWD --key-pass pass:$KEYSTORE_ENC_PWD --v1-signing-enabled true --v2-signing-enabled true --in $UNSIGNED_APK_PATH --out $SIGNED_APK_PATH | |
- name: Upload Artifact | |
uses: actions/upload-artifact@v2 | |
with: | |
name: NEVideoCall-Android-Java | |
path: ./NLiteAVDemo-Android-Java/app/build/outputs/apk/release/NEVideoCall-Android-Java.apk |