Android一键打包(react native)

Android自动化打包配置截图如下:

Android一键打包(react native)

 

Android一键打包(react native)

 

Android一键打包(react native)

 

Android一键打包(react native)

 

export YARN_HOME=/usr/local/Cellar/yarn/1.5.1_1/bin
export PATH=$PATH:$YARN_HOME
export NODE_HOME=/Users/devops/.nvm/versions/node/v10.8.0
export PATH=$NODE_HOME/bin:$PATH
export POD_HOME=/Users/devops/.rvm/gems/ruby-2.4.0
export PATH=$POD_HOME/bin:$PATH
export ANDROID_HOME=/Users/devops/Library/Android/sdk
# export http_proxy=http://127.0.0.1:1087;export https_proxy=http://127.0.0.1:1087;
echo $PATH
yarn install
#cnpm install
react-native bundle --entry-file index.js --platform android --dev false --bundle-output ./android/app/src/main/assets/index.android.bundle --assets-dest ./android/app/src/main/res/
cd android && ./gradlew assembleRelease -x lint

#file=‘find . -name *.apk‘
#curl -F "file=@$file" -F "uKey=1367d748482b5c460ba7a750dd4b41ca" -F "_api_key=dc3c75b8c1d8e264a286414478b4d372" https://www.pgyer.com/apiv1/app/upload
#Debug
#curl -F "file=@/Users/devops/.jenkins/workspace/Starup_Android/app/build/outputs/apk/local/debug/localDebug-debug-local.apk" -F "uKey=1367d748482b5c460ba7a750dd4b41ca" -F "_api_key=dc3c75b8c1d8e264a286414478b4d372" https://www.pgyer.com/apiv1/app/upload
curl -F "file=@/Users/devops/.jenkins/workspace/poseidon_android/android/app/build/outputs/apk/release/app-release.apk" -F "uKey=1367d748482b5c460ba7a750dd4b41ca" -F "_api_key=dc3c75b8c1d8e264a286414478b4d372" https://www.pgyer.com/apiv1/app/upload
#Release
#curl -F "file=@/Users/devops/.jenkins/workspace/Starup_Android/app/build/outputs/apk/local/release/localRelease-release-local.apk" -F "uKey=1367d748482b5c460ba7a750dd4b41ca" -F "_api_key=dc3c75b8c1d8e264a286414478b4d372" https://www.pgyer.com/apiv1/app/upload

Android一键打包(react native)

上一篇:VS动态修改App.config中遇到的坑(宿主进程问题)


下一篇:Xamarin.Android 启动页