Skip to content

Commit

Permalink
Merge pull request #10 from Automattic/issue/fix-flowconfig
Browse files Browse the repository at this point in the history
Exclude some of the libraries from the flow analysis and update travis
  • Loading branch information
hypest committed Mar 16, 2018
2 parents 014ca8c + e7ad3fa commit ca4d0be
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 2 deletions.
8 changes: 8 additions & 0 deletions .flowconfig
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,14 @@
<PROJECT_ROOT>/node_modules/xdl/.*
<PROJECT_ROOT>/node_modules/reqwest/.*
<PROJECT_ROOT>/node_modules/metro-bundler/.*
<PROJECT_ROOT>/node_modules/fbjs/.*
<PROJECT_ROOT>/node_modules/graphql/.*
<PROJECT_ROOT>/node_modules/prettier/.*

; Gutenberg tools
<PROJECT_ROOT>/gutenberg/node_modules/findup/.*
<PROJECT_ROOT>/gutenberg/node_modules/cypress/.*
<PROJECT_ROOT>/gutenberg/node_modules/config-chain/.*

; Hack to make Flow works on OS X with a RN project
<PROJECT_ROOT>/node_modules/metro/.*
Expand Down
6 changes: 4 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
before_script:
- yarn install

matrix:
include:
- language: node_js
Expand All @@ -6,5 +9,4 @@ matrix:
cache:
yarn: true
script:
- yarn install
- npm run flow
- ./.travis/travis-checks-js.sh
11 changes: 11 additions & 0 deletions .travis/travis-checks-js.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
function pOk() {
echo "[$(tput setaf 2)OK$(tput sgr0)]"
}

function pFail() {
echo "[$(tput setaf 1)KO$(tput sgr0)]"
exit 1
}

npm run flow || pFail
npm run prettier-check || pFail

0 comments on commit ca4d0be

Please sign in to comment.