Skip to content

Commit 9b9c1d5

Browse files
authored
feat: setup github actions (#46)
1 parent c786578 commit 9b9c1d5

File tree

3 files changed

+115
-156
lines changed

3 files changed

+115
-156
lines changed

.circleci/config.yml

Lines changed: 0 additions & 154 deletions
This file was deleted.

.github/workflows/ci.yml

Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
name: Build
2+
on: pull_request
3+
4+
jobs:
5+
lint:
6+
runs-on: ubuntu-18.04
7+
strategy:
8+
matrix:
9+
node-version: [10]
10+
steps:
11+
- uses: actions/checkout@v2
12+
- uses: actions/setup-node@v1
13+
with:
14+
node-version: ${{ matrix.node-version }}
15+
- name: Get yarn cache
16+
id: yarn-cache
17+
run: echo "::set-output name=dir::$(yarn cache dir)"
18+
- uses: actions/cache@v2
19+
with:
20+
path: ${{ steps.yarn-cache.outputs.dir }}
21+
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
22+
- name: Install Dependencies
23+
run: yarn
24+
- name: ESLint Checks
25+
run: yarn lint
26+
flow:
27+
runs-on: ubuntu-18.04
28+
strategy:
29+
matrix:
30+
node-version: [10]
31+
steps:
32+
- uses: actions/checkout@v2
33+
- uses: actions/setup-node@v1
34+
with:
35+
node-version: ${{ matrix.node-version }}
36+
- name: Get yarn cache
37+
id: yarn-cache
38+
run: echo "::set-output name=dir::$(yarn cache dir)"
39+
- uses: actions/cache@v2
40+
with:
41+
path: ${{ steps.yarn-cache.outputs.dir }}
42+
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
43+
- name: Install Dependencies
44+
run: yarn
45+
- name: FlowType Check
46+
run: yarn flow
47+
tsc:
48+
runs-on: ubuntu-18.04
49+
strategy:
50+
matrix:
51+
node-version: [10]
52+
steps:
53+
- uses: actions/checkout@v2
54+
- uses: actions/setup-node@v1
55+
with:
56+
node-version: ${{ matrix.node-version }}
57+
- name: Get yarn cache
58+
id: yarn-cache
59+
run: echo "::set-output name=dir::$(yarn cache dir)"
60+
- uses: actions/cache@v2
61+
with:
62+
path: ${{ steps.yarn-cache.outputs.dir }}
63+
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
64+
- name: Install Dependencies
65+
run: yarn
66+
- name: TypeScript type check
67+
run: yarn type-check
68+
android:
69+
runs-on: ubuntu-18.04
70+
strategy:
71+
matrix:
72+
node-version: [10]
73+
steps:
74+
- uses: actions/checkout@v2
75+
- uses: actions/setup-node@v1
76+
with:
77+
node-version: ${{ matrix.node-version }}
78+
- name: Get yarn cache
79+
id: yarn-cache
80+
run: echo "::set-output name=dir::$(yarn cache dir)"
81+
- uses: actions/cache@v2
82+
with:
83+
path: ${{ steps.yarn-cache.outputs.dir }}
84+
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
85+
- name: Install Dependencies
86+
run: yarn
87+
- name: Build Android Example App and Library
88+
run: cd example/android && ./gradlew clean assembleDebug
89+
ios:
90+
runs-on: macos-latest
91+
strategy:
92+
matrix:
93+
node-version: [10]
94+
steps:
95+
- uses: actions/checkout@v2
96+
- uses: actions/setup-node@v1
97+
with:
98+
node-version: ${{ matrix.node-version }}
99+
- name: Get yarn cache
100+
id: yarn-cache
101+
run: echo "::set-output name=dir::$(yarn cache dir)"
102+
- uses: actions/cache@v2
103+
with:
104+
path: ${{ steps.yarn-cache.outputs.dir }}
105+
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
106+
- name: Install Dependencies
107+
run: yarn
108+
- name: Install Podfiles
109+
run: cd example && npx pod-install
110+
- name: Build example app
111+
run: yarn ios

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# @react-native-community/progress-view
22

33
[![Build Status][build-badge]][build]
4+
[![Windows CI Status][windows-ci-badge]][build]
45
[![Version][version-badge]][package]
56
![Platforms][support-badge]
67
[![MIT License][license-badge]][license]
@@ -211,8 +212,9 @@ Turns progress bar into an indeterminate progress bar
211212

212213
The library is released under the MIT license. For more information see [`LICENSE`](/LICENSE).
213214

214-
[build-badge]: https://img.shields.io/circleci/project/github/react-native-community/progress-view/master.svg?style=flat-square
215-
[build]: https://circleci.com/gh/react-native-community/progress-view
215+
[build-badge]: https://github.com/react-native-community/progress-view/workflows/Build/badge.svg
216+
[windows-ci-badge]:https://github.com/react-native-community/progress-view/workflows/Windows%20CI/badge.svg
217+
[build]: https://github.com/react-native-community/progress-view/actions
216218
[version-badge]: https://img.shields.io/npm/v/@react-native-community/progress-view.svg?style=flat-square
217219
[package]: https://www.npmjs.com/package/@react-native-community/progress-view
218220
[support-badge]:https://img.shields.io/badge/platforms-ios%20|%20macos-lightgrey.svg?style=flat-square

0 commit comments

Comments
 (0)