File tree Expand file tree Collapse file tree 2 files changed +13
-6
lines changed Expand file tree Collapse file tree 2 files changed +13
-6
lines changed Original file line number Diff line number Diff line change @@ -110,7 +110,7 @@ jobs:
110110 if : ${{ matrix.platform == 'android' }}
111111 with :
112112 name : ' AndroidAPK${{ matrix.react-native-version }}'
113- path : ./Apps/BRNPlayground/android/app/build/outputs/ apk/release
113+ path : ./Apps/BRNPlayground/apk
114114 - name : Upload iOS App
115115 uses : actions/upload-artifact@v4
116116 if : ${{ matrix.platform == 'ios' }}
Original file line number Diff line number Diff line change @@ -103,12 +103,19 @@ const buildAndroid = async () => {
103103const buildAndroidRNTA = async ( ) => {
104104 const basekitBuildProp = basekitBuild ? "-PBASEKIT_BUILD=1" : "" ;
105105 exec ( `./gradlew app:assembleRelease --stacktrace --info ${ basekitBuildProp } ` , '../Apps/BRNPlayground/android' ) ;
106- const baseKitOrFull = basekitBuild ? '-basekit' : '-full ' ;
107- const oldPath = '../Apps/BRNPlayground/android/app/build/outputs/apk/release/app-release.apk' ;
108- const newPath = `../Apps/BRNPlayground/android/app/build/outputs/apk/release/ app-release${ baseKitOrFull } .apk` ;
106+ const baseKitOrFull = basekitBuild ? '-basekit' : '' ;
107+ const srcFile = '../Apps/BRNPlayground/android/app/build/outputs/apk/release/app-release.apk' ;
108+ const newName = `app-release${ baseKitOrFull } .apk` ;
109109
110- fs . rename ( oldPath , newPath , function ( err ) {
111- if ( err ) throw err ;
110+ const apkFolder = '../Apps/BRNPlayground/apk' ;
111+ if ( ! fs . existsSync ( apkFolder ) ) {
112+ fs . mkdirSync ( apkFolder , { recursive : true } ) ;
113+ }
114+ await new Promise ( resolve => {
115+ gulp . src ( srcFile )
116+ . pipe ( rename ( newName ) )
117+ . pipe ( gulp . dest ( apkFolder ) )
118+ . on ( 'end' , resolve ) ;
112119 } ) ;
113120} ;
114121
You can’t perform that action at this time.
0 commit comments