Cancel split abi

pull/28/head
fengyuecanzhu 2 years ago
parent c1dabd3b8d
commit 5129ad6838
No known key found for this signature in database
GPG Key ID: 04B78AD06A9D6E6C
  1. 36
      .github/workflows/build.yml
  2. 17
      app/build.gradle

@ -80,40 +80,12 @@ jobs:
tag_name: ${{ steps.config.outputs.version_name }} tag_name: ${{ steps.config.outputs.version_name }}
name: FYReader_${{ steps.config.outputs.version_name }} name: FYReader_${{ steps.config.outputs.version_name }}
files: | files: |
${{ steps.get_path.outputs.file_path }}/风月读书${{ steps.config.outputs.version_name }}-arm64-v8a.apk ${{ steps.get_path.outputs.file_path }}/风月读书${{ steps.config.outputs.version_name }}.apk
${{ steps.get_path.outputs.file_path }}/风月读书${{ steps.config.outputs.version_name }}-armeabi-v7a.apk
${{ steps.get_path.outputs.file_path }}/风月读书${{ steps.config.outputs.version_name }}-x86_64.apk
${{ steps.get_path.outputs.file_path }}/风月读书${{ steps.config.outputs.version_name }}-x86.apk
${{ steps.get_path.outputs.file_path }}/风月读书${{ steps.config.outputs.version_name }}-universal.apk
env: env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# 上传Artifact # 上传Artifact
- name: Upload Artifact arm64-v8a - name: Upload Artifact
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v3
with: with:
name: app-arm64-v8a name: app
path: ${{ steps.get_path.outputs.file_path }}/风月读书${{ steps.config.outputs.version_name }}-arm64-v8a.apk path: ${{ steps.get_path.outputs.file_path }}/风月读书${{ steps.config.outputs.version_name }}.apk
- name: Upload Artifact armeabi-v7a
uses: actions/upload-artifact@v3
with:
name: app-armeabi-v7a
path: ${{ steps.get_path.outputs.file_path }}/风月读书${{ steps.config.outputs.version_name }}-armeabi-v7a.apk
- name: Upload Artifact universal
uses: actions/upload-artifact@v3
with:
name: app-universal
path: ${{ steps.get_path.outputs.file_path }}/风月读书${{ steps.config.outputs.version_name }}-universal.apk
- name: Upload Artifact x86_64
uses: actions/upload-artifact@v3
with:
name: app-x86_64
path: ${{ steps.get_path.outputs.file_path }}/风月读书${{ steps.config.outputs.version_name }}-x86_64.apk
- name: Upload Artifact x86
uses: actions/upload-artifact@v3
with:
name: app-x86
path: ${{ steps.get_path.outputs.file_path }}/风月读书${{ steps.config.outputs.version_name }}-x86.apk

@ -78,14 +78,14 @@ android {
viewBinding true viewBinding true
} }
splits { /*splits {
abi { abi {
reset() reset()
enable true enable true
universalApk true // If true, also generate a universal APK universalApk true // If true, also generate a universal APK
include "armeabi-v7a", "arm64-v8a", "x86", "x86_64" include "armeabi-v7a", "arm64-v8a", "x86", "x86_64"
} }
} }*/
buildTypes { buildTypes {
release { release {
@ -94,6 +94,9 @@ android {
if (keyPropsFile.exists()) { if (keyPropsFile.exists()) {
signingConfig signingConfigs.myConifg signingConfig signingConfigs.myConifg
} }
ndk {
abiFilters "armeabi-v7a", "arm64-v8a", "x86", "x86_64"
}
} }
debug { debug {
minifyEnabled false minifyEnabled false
@ -103,16 +106,22 @@ android {
} }
applicationIdSuffix ".debug" applicationIdSuffix ".debug"
versionNameSuffix "-" + commitId versionNameSuffix "-" + commitId
ndk {
abiFilters "arm64-v8a"
}
} }
android.applicationVariants.all { variant -> android.applicationVariants.all { variant ->
variant.outputs.each { output -> variant.outputs.all {
outputFileName = "${name}v${defaultConfig.versionName}.apk"
}
/*variant.outputs.each { output ->
def abi = output.getFilter(OutputFile.ABI) def abi = output.getFilter(OutputFile.ABI)
if (abi == null) { if (abi == null) {
abi = "universal" abi = "universal"
} }
def fileName = "${name}v${defaultConfig.versionName}-${abi}.apk" def fileName = "${name}v${defaultConfig.versionName}-${abi}.apk"
output.outputFileName = fileName output.outputFileName = fileName
} }*/
} }
} }
sourceSets.main { sourceSets.main {

Loading…
Cancel
Save