-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit b8f5c19
Showing
102 changed files
with
20,460 additions
and
0 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,6 @@ | ||
|
||
[android] | ||
target = Google Inc.:Google APIs:23 | ||
|
||
[maven_repositories] | ||
central = https://repo1.maven.org/maven2 |
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,7 @@ | ||
{ | ||
"extends": ["taro/react"], | ||
"rules": { | ||
"react/jsx-uses-react": "off", | ||
"react/react-in-jsx-scope": "off" | ||
} | ||
} |
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,66 @@ | ||
[ignore] | ||
; We fork some components by platform | ||
.*/*[.]android.js | ||
|
||
; Ignore "BUCK" generated dirs | ||
<PROJECT_ROOT>/\.buckd/ | ||
|
||
; Ignore polyfills | ||
node_modules/react-native/Libraries/polyfills/.* | ||
|
||
; Flow doesn't support platforms | ||
.*/Libraries/Utilities/LoadingView.js | ||
|
||
.*/node_modules/resolve/test/resolver/malformed_package_json/package\.json$ | ||
|
||
[untyped] | ||
.*/node_modules/@react-native-community/cli/.*/.* | ||
|
||
[include] | ||
|
||
[libs] | ||
node_modules/react-native/interface.js | ||
node_modules/react-native/flow/ | ||
|
||
[options] | ||
emoji=true | ||
|
||
exact_by_default=true | ||
|
||
format.bracket_spacing=false | ||
|
||
module.file_ext=.js | ||
module.file_ext=.json | ||
module.file_ext=.ios.js | ||
|
||
munge_underscores=true | ||
|
||
module.name_mapper='^react-native/\(.*\)$' -> '<PROJECT_ROOT>/node_modules/react-native/\1' | ||
module.name_mapper='^@?[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> '<PROJECT_ROOT>/node_modules/react-native/Libraries/Image/RelativeImageStub' | ||
|
||
suppress_type=$FlowIssue | ||
suppress_type=$FlowFixMe | ||
suppress_type=$FlowFixMeProps | ||
suppress_type=$FlowFixMeState | ||
|
||
[lints] | ||
sketchy-null-number=warn | ||
sketchy-null-mixed=warn | ||
sketchy-number=warn | ||
untyped-type-import=warn | ||
nonstrict-import=warn | ||
deprecated-type=warn | ||
unsafe-getters-setters=warn | ||
unnecessary-invariant=warn | ||
|
||
[strict] | ||
deprecated-type | ||
nonstrict-import | ||
sketchy-null | ||
unclear-type | ||
unsafe-getters-setters | ||
untyped-import | ||
untyped-type-import | ||
|
||
[version] | ||
^0.182.0 |
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,15 @@ | ||
#!/bin/bash | ||
|
||
set -euo pipefail | ||
|
||
security create-keychain -p "" build.keychain | ||
security list-keychains -s build.keychain | ||
security default-keychain -s build.keychain | ||
security unlock-keychain -p "" build.keychain | ||
security set-keychain-settings | ||
security import <(echo $SIGNING_CERTIFICATE_P12_DATA | base64 --decode) \ | ||
-f pkcs12 \ | ||
-k build.keychain \ | ||
-P $SIGNING_CERTIFICATE_PASSWORD \ | ||
-T /usr/bin/codesign | ||
security set-key-partition-list -S apple-tool:,apple: -s -k "" build.keychain |
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,6 @@ | ||
#!/bin/bash | ||
|
||
set -euo pipefail | ||
|
||
mkdir -p ~/Library/MobileDevice/Provisioning\ Profiles | ||
echo "$PROVISIONING_PROFILE_DATA" | base64 --decode > ~/Library/MobileDevice/Provisioning\ Profiles/profile.mobileprovision |
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,93 @@ | ||
# 工作流名称 | ||
name: Assemble Android Debug | ||
|
||
# 触发工作流程的事件 | ||
on: | ||
push: | ||
branches: [ master ] | ||
tags: [ v* ] | ||
pull_request: | ||
branches: [ master ] | ||
|
||
workflow_dispatch: | ||
|
||
# 工作流环境变量 | ||
env: | ||
# 应用的application_id | ||
APP_ID: com.tarodemo | ||
# 应用名称 | ||
APP_NAME: Taro Demo | ||
# 打包类型 | ||
BUILD_TYPE: debug | ||
# 版本名称 | ||
VERSION_NAME: 1.0.0 | ||
# 版本号 | ||
VERSION_CODE: 10 | ||
# 密钥库文件 | ||
KEYSTORE_FILE: debug.keystore | ||
# 密钥库口令 | ||
KEYSTORE_PASSWORD: android | ||
# 密钥库别名 | ||
KEYSTORE_KEY_ALIAS: androiddebugkey | ||
# 密钥库别名口令 | ||
KEYSTORE_KEY_PASSWORD: android | ||
|
||
# 工作流作业 | ||
jobs: | ||
assemble: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Project | ||
uses: actions/checkout@v2 | ||
- name: Cache node_modules Folder | ||
uses: actions/cache@v2 | ||
with: | ||
path: ${{ github.workspace }}/node_modules | ||
key: ${{ runner.os }}-node_modules | ||
restore-keys: ${{ runner.os }}-node_modules | ||
- name: Get Yarn Cache Directory Path | ||
id: yarn-cache-dir-path | ||
run: echo "::set-output name=dir::$(yarn cache dir)" | ||
- name: Cache Yarn | ||
uses: actions/cache@v2 | ||
env: | ||
cache-name: yarn-cache | ||
with: | ||
path: ${{ steps.yarn-cache-dir-path.outputs.dir }} | ||
key: ${{ runner.os }}-yarn-${{ hashFiles('**/package.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-yarn- | ||
- name: Install Dependencies | ||
run: | | ||
yarn | ||
- name: Cache Gradle | ||
uses: actions/cache@v2 | ||
env: | ||
cache-name: gradle-cache | ||
with: | ||
path: ~/.gradle | ||
key: ${{ runner.os }}-gradle | ||
restore-keys: | | ||
${{ runner.os }}-gradle | ||
- name: Assemble Android ${{ env.BUILD_TYPE }} | ||
run: | | ||
sudo apt install -y ruby-bundler | ||
cd android | ||
bundle update | ||
bundle exec fastlane assemble | ||
env: | ||
KEYSTORE_FILE: ${{ github.workspace }}/android/app/${{ env.KEYSTORE_FILE }} | ||
- name: Upload Android Products | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: app-${{ env.BUILD_TYPE }} | ||
path: ${{ github.workspace }}/android/app/build/outputs/apk/${{ env.BUILD_TYPE }}/app-${{ env.BUILD_TYPE }}.apk | ||
- name: Upload release assets | ||
uses: softprops/action-gh-release@v1 | ||
if: startsWith(github.ref, 'refs/tags/') | ||
with: | ||
prerelease: ${{ contains(github.ref, 'beta') }} | ||
files: | | ||
android/app/build/outputs/apk/${{ env.BUILD_TYPE }}/app-${{ env.BUILD_TYPE }}.apk | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
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,93 @@ | ||
# 工作流名称 | ||
name: Assemble Android Release | ||
|
||
# 触发工作流程的事件 | ||
on: | ||
push: | ||
branches: [ master ] | ||
tags: [ v* ] | ||
pull_request: | ||
branches: [ master ] | ||
|
||
workflow_dispatch: | ||
|
||
# 工作流环境变量 | ||
env: | ||
# 应用的application_id | ||
APP_ID: com.tarodemo | ||
# 应用名称 | ||
APP_NAME: Taro Demo | ||
# 打包类型 | ||
BUILD_TYPE: release | ||
# 版本名称 | ||
VERSION_NAME: 1.0.0 | ||
# 版本号 | ||
VERSION_CODE: 10 | ||
# 密钥库文件 | ||
KEYSTORE_FILE: debug.keystore | ||
# 密钥库口令 | ||
KEYSTORE_PASSWORD: android | ||
# 密钥库别名 | ||
KEYSTORE_KEY_ALIAS: androiddebugkey | ||
# 密钥库别名口令 | ||
KEYSTORE_KEY_PASSWORD: android | ||
|
||
# 工作流作业 | ||
jobs: | ||
assemble: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Project | ||
uses: actions/checkout@v2 | ||
- name: Cache node_modules Folder | ||
uses: actions/cache@v2 | ||
with: | ||
path: ${{ github.workspace }}/node_modules | ||
key: ${{ runner.os }}-node_modules | ||
restore-keys: ${{ runner.os }}-node_modules | ||
- name: Get Yarn Cache Directory Path | ||
id: yarn-cache-dir-path | ||
run: echo "::set-output name=dir::$(yarn cache dir)" | ||
- name: Cache Yarn | ||
uses: actions/cache@v2 | ||
env: | ||
cache-name: yarn-cache | ||
with: | ||
path: ${{ steps.yarn-cache-dir-path.outputs.dir }} | ||
key: ${{ runner.os }}-yarn-${{ hashFiles('**/package.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-yarn- | ||
- name: Install Dependencies | ||
run: | | ||
yarn | ||
- name: Cache Gradle | ||
uses: actions/cache@v2 | ||
env: | ||
cache-name: gradle-cache | ||
with: | ||
path: ~/.gradle | ||
key: ${{ runner.os }}-gradle | ||
restore-keys: | | ||
${{ runner.os }}-gradle | ||
- name: Assemble Android ${{ env.BUILD_TYPE }} | ||
run: | | ||
sudo apt install -y ruby-bundler | ||
cd android | ||
bundle update | ||
bundle exec fastlane assemble | ||
env: | ||
KEYSTORE_FILE: ${{ github.workspace }}/android/app/${{ env.KEYSTORE_FILE }} | ||
- name: Upload Android Products | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: app-${{ env.BUILD_TYPE }} | ||
path: ${{ github.workspace }}/android/app/build/outputs/apk/${{ env.BUILD_TYPE }}/app-${{ env.BUILD_TYPE }}.apk | ||
- name: Upload release assets | ||
uses: softprops/action-gh-release@v1 | ||
if: startsWith(github.ref, 'refs/tags/') | ||
with: | ||
prerelease: ${{ contains(github.ref, 'beta') }} | ||
files: | | ||
android/app/build/outputs/apk/${{ env.BUILD_TYPE }}/app-${{ env.BUILD_TYPE }}.apk | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
Oops, something went wrong.