Skip to content

Commit

Permalink
add windows ci (#20281)
Browse files Browse the repository at this point in the history
Summary:
[![Build status](https://ci.appveyor.com/api/projects/status/79bl3twr4palqmra/branch/feature/appveyor?svg=true)](https://ci.appveyor.com/project/gengjiawen/react-native/branch/master)
Add windows ci
pass all current ci.
none
 [GENERAL] [INTERNAL] [CI] - add windows ci
Pull Request resolved: #20281

Differential Revision: D8924625

Pulled By: hramos

fbshipit-source-id: 6b933a8affe7c131c0fd02694f6177885a196611
  • Loading branch information
gengjiawen authored and facebook-github-bot committed Jul 19, 2018
1 parent ca01290 commit 1b2a552
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# [React Native](https://facebook.github.io/react-native/) · [![Circle CI Status](https://circleci.com/gh/facebook/react-native.svg?style=shield)](https://circleci.com/gh/facebook/react-native) [![npm version](https://badge.fury.io/js/react-native.svg)](https://badge.fury.io/js/react-native) [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](CONTRIBUTING.md#pull-requests)
# [React Native](https://facebook.github.io/react-native/) · [![Circle CI Status](https://circleci.com/gh/facebook/react-native.svg?style=shield)](https://circleci.com/gh/facebook/react-native) [![Build status](https://ci.appveyor.com/api/projects/status/github/facebook/react-native?branch=master&svg=true)](https://ci.appveyor.com/project/facebok/react-native/branch/master) [![npm version](https://badge.fury.io/js/react-native.svg)](https://badge.fury.io/js/react-native) [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](CONTRIBUTING.md#pull-requests)

Learn once, write anywhere: Build mobile apps with React.

Expand Down
42 changes: 42 additions & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
environment:
ANDROID_HOME: "C:\\android-sdk-windows"
ANDROID_NDK: "C:\\android-sdk-windows\\android-ndk-r10e"
ANDROID_BUILD_VERSION: 26
ANDROID_TOOLS_VERSION: 26.0.3

GRADLE_OPTS: -Dorg.gradle.daemon=false

SDK_TOOLS_URL: https://dl.google.com/android/repository/sdk-tools-windows-3859397.zip
NDK_TOOLS_URL: https://dl.google.com/android/repository/android-ndk-r10e-windows-x86_64.zip

matrix:
- nodejs_version: 8
- nodejs_version: 10

install:
# Install Android SDK Tools
- mkdir "%ANDROID_HOME%"
- appveyor DownloadFile "%SDK_TOOLS_URL%" -FileName "%TMP%/sdk-tools.zip"
- 7z x "%TMP%/sdk-tools.zip" -o"%ANDROID_HOME%" > nul
- set PATH=%PATH%;"%ANDROID_HOME%\tools\bin"

- yes 2> nul | sdkmanager --licenses > nul
- sdkmanager "system-images;android-19;google_apis;armeabi-v7a"
- sdkmanager "platforms;android-%ANDROID_BUILD_VERSION%"
- sdkmanager "build-tools;%ANDROID_TOOLS_VERSION%"
- sdkmanager "add-ons;addon-google_apis-google-23"
- sdkmanager "extras;android;m2repository"

- appveyor DownloadFile "%NDK_TOOLS_URL%" -FileName "%TMP%/ndk.zip"
- 7z x "%TMP%/ndk.zip" -o"%ANDROID_HOME%" > nul

- ps: Install-Product node $env:nodejs_version
- node --version
- npm --version
- appveyor-retry npm install

build_script:
- gradlew.bat RNTester:android:app:assembleRelease

test_script:
- npm test

0 comments on commit 1b2a552

Please sign in to comment.