Skip to content

Commit

Permalink
[PR] Publish Windows binary from Circle, remove Appveyor
Browse files Browse the repository at this point in the history
Summary: Pull Request resolved: facebook#8261

Differential Revision: D19382157

Pulled By: mroch

fbshipit-source-id: d75339b02cfc62994ce4129c8fef02c0aa6e6c4b
  • Loading branch information
mroch authored and facebook-github-bot committed Jan 14, 2020
1 parent 204b19d commit cf88da1
Show file tree
Hide file tree
Showing 6 changed files with 53 additions and 128 deletions.
59 changes: 53 additions & 6 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ orbs:
environment:
PATH: /usr/local/bin:/usr/bin:/cygdrive/c/Windows/system32:/cygdrive/c/Windows:/cygdrive/c/Windows/System32/Wbem:/cygdrive/c/Windows/System32/WindowsPowerShell/v1.0
command: |
[ -d _opam ] || opam switch create . ocaml-variants.4.07.1+mingw64c --deps-only --yes
[ -d _opam ] || opam switch create . ocaml-variants.4.07.1+mingw64c --deps-only --yes -vvv
executors:
linux-opam:
Expand Down Expand Up @@ -266,7 +266,8 @@ jobs:
name: Calculate opam version
shell: C:/tools/cygwin/bin/bash.exe --noprofile --norc -eo pipefail
command: /usr/local/bin/opam --version > /cygdrive/c/tmp/flow/opamversion
- checkout
- attach_workspace:
at: .
- restore_cache:
keys:
- opam-cache-{{ arch }}-opam_{{ checksum "C:/tmp/flow/opamversion" }}-ocaml_4_07_1-{{ checksum "opam" }}
Expand All @@ -287,11 +288,21 @@ jobs:
make bin/flow.exe dist/flow.zip
mkdir -p bin/win64 && cp bin/flow.exe bin/win64/flow.exe
cp dist/flow.zip dist/flow-win64.zip
- run:
name: Build parser test runner
shell: C:/tools/cygwin/bin/bash.exe --noprofile --norc -eo pipefail
environment:
PATH: /usr/local/bin:/usr/bin:/cygdrive/c/Windows/system32:/cygdrive/c/Windows:/cygdrive/c/Windows/System32/Wbem:/cygdrive/c/Windows/System32/WindowsPowerShell/v1.0
command: |
eval $(opam env)
make -C src/parser/ ../../_build/src/parser/test/run_tests.native
cp _build/src/parser/test/run_tests.native bin/win64/run_parser_tests.exe
- persist_to_workspace:
root: .
paths:
- bin/win64/flow.exe
- dist/flow-win64.zip
- bin/win64/run_parser_tests.exe
- store_artifacts:
path: .\dist\flow-win64.zip
destination: flow-win64.zip
Expand Down Expand Up @@ -343,21 +354,33 @@ jobs:
tool_test_win:
executor: win/default
steps:
- checkout
- attach_workspace:
at: ./artifacts
at: .
- run:
name: Install Yarn
command: choco install yarn
- run:
name: Install tool deps from yarn
command: |
cd packages/flow-dev-tools
yarn install
yarn install --ignore-scripts --pure-lockfile
- run:
name: Run tool tests
shell: bash
command: ./tool test --bin artifacts/bin/win64/flow.exe --parallelism 1 --max-errored-tests-pct 20
command: ./tool test --bin bin/win64/flow.exe --parallelism 1 --max-errored-tests-pct 20

parser_test_win:
executor: win/default
steps:
- attach_workspace:
at: .
- run:
name: Test parser
command: |
.\bin\win64\run_parser_tests.exe .\src\parser\test\flow\
if ($LASTEXITCODE -gt 0) {
Throw "flow parser hardcoded ocaml tests exited with error code: $LASTEXITCODE"
}
npm_pack:
executor: linux-node
Expand Down Expand Up @@ -438,6 +461,15 @@ jobs:
name: Upload Mac libflowparser
command: .circleci/github_upload.sh dist/libflowparser-osx.zip "libflowparser-osx-$CIRCLE_TAG.zip"

github_win:
executor: curl
steps:
- attach_workspace:
at: /flow
- run:
name: Upload Windows binary
command: .circleci/github_upload.sh dist/flow-win64.zip "flow-win64-$CIRCLE_TAG.zip"

website_deploy:
executor: flow-website
steps:
Expand Down Expand Up @@ -506,6 +538,8 @@ workflows:
- checkout
- build_win:
<<: *run_on_tags
requires:
- checkout
- runtests_linux:
<<: *run_on_tags
requires:
Expand All @@ -526,6 +560,10 @@ workflows:
<<: *run_on_tags
requires:
- build_win
- parser_test_win:
<<: *run_on_tags
requires:
- build_win
- npm_pack:
<<: *run_on_tags
requires:
Expand Down Expand Up @@ -557,6 +595,15 @@ workflows:
only: /^v.*/
branches:
ignore: /.*/
- github_win:
requires:
- tool_test_win
- parser_test_win
filters:
tags:
only: /^v.*/
branches:
ignore: /.*/

# only deploy the website from master, so that it can include docs/blog
# posts about an upcoming release, and so the release branch doesn't
Expand Down
45 changes: 0 additions & 45 deletions appveyor.yml

This file was deleted.

13 changes: 0 additions & 13 deletions resources/appveyor/after_build.ps1

This file was deleted.

24 changes: 0 additions & 24 deletions resources/appveyor/build.sh

This file was deleted.

19 changes: 0 additions & 19 deletions resources/appveyor/install.ps1

This file was deleted.

21 changes: 0 additions & 21 deletions resources/appveyor/test.ps1

This file was deleted.

0 comments on commit cf88da1

Please sign in to comment.