Skip to content

Instantly share code, notes, and snippets.

@leotsem
Created October 15, 2017 23:38
Show Gist options
  • Save leotsem/7fe5c2907aee49fa014ea0e3b70cf5cc to your computer and use it in GitHub Desktop.
Save leotsem/7fe5c2907aee49fa014ea0e3b70cf5cc to your computer and use it in GitHub Desktop.
Circle CI config for react native apps using jest
machine:
environment:
YARN_VERSION: 0.18.1
PATH: "${PATH}:${HOME}/.yarn/bin:${HOME}/${CIRCLE_PROJECT_REPONAME}/node_modules/.bin"
dependencies:
pre:
- |
if [[ ! -e ~/.yarn/bin/yarn || $(yarn --version) != "${YARN_VERSION}" ]]; then
echo "Download and install Yarn."
curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version $YARN_VERSION
else
echo "The correct version of Yarn is already installed."
fi
cache_directories:
- ~/.yarn
- ~/.cache/yarn
override:
- yarn install
test:
override:
- yarn test
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment