forked from facebook/react-native-website
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfig.yml
76 lines (69 loc) · 1.69 KB
/
config.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
version: 2.1
# -------------------------
# EXECUTORS
# -------------------------
executors:
node:
docker:
- image: circleci/node:lts
# -------------------------
# COMMANDS
# -------------------------
commands:
restore_cache_checkout:
steps:
- restore_cache:
key: v1-repo-{{ .Environment.CIRCLE_SHA1 }}
run_yarn:
steps:
- restore_cache:
keys:
- v1-yarn-{{ .Branch }}
- run:
name: Yarn Install
command: yarn install --no-progress --non-interactive --cache-folder ~/.cache/yarn
- save_cache:
paths:
- node_modules
- ~/.cache/yarn
key: v1-yarn-{{ .Branch }}
# -------------------------
# JOBS
# -------------------------
jobs:
# --------------------------------------------------
# JOB: setup
# Checks out the repo, and persists to cache.
# --------------------------------------------------
setup:
executor: node
working_directory: ~/react-native-website
steps:
- checkout
- save_cache:
key: v1-repo-{{ .Environment.CIRCLE_SHA1 }}
paths:
- ~/react-native-website
# --------------------------------------------------
# JOB: lint
# Lint the docs.
# --------------------------------------------------
lint:
executor: node
working_directory: ~/react-native-website/website
steps:
- restore_cache_checkout
- run_yarn
- run: yarn ci:lint
# -------------------------
# WORKFLOWS
# -------------------------
workflows:
# Tests run on master and on forks
tests:
jobs:
- setup
# Run lints
- lint:
requires:
- setup