Skip to content

Commit

Permalink
Replace Travis with Github Actions (mhallin#15)
Browse files Browse the repository at this point in the history
* fix: probably fix windows build

* fix: build

* Rename nodejs.yml to test.yml

* Update and rename test.yml to main.yml

* Update main.yml

* Update main.yml

* Update main.yml

* Update main.yml

* Update main.yml

* Update main.yml

* Update main.yml

* Update main.yml

* Update CI

* fix: esy build

* fix: disable windows build

* fix: reorder workflow

* fix: typo

* fix: try to fix

* fix: try to figure out env variables

* ci: another attempt

* another ...

* another ...

* try release

* fix: copy :P

* fix: copy :P

* ci: another fix

* feat: try release

* feat: remove travis ci

* chore: remove traivis badge

* ci: run release job only on release

* ci: fix

* ci: remove pull_request trigger

* ci: pin menhir version for windows build

* ci: pin menhir version for windows build

* ci: make windows work

* ci: fix setting env in windows

* ci: windows ....

* ci: remove old ci stuff

* ci: install cross-env global for windows

* fix: improve publish step

* fix: try make windows work again pliz

* fix: windows doesn't like comments :/

* fix: windows ci

* fix: another one for windows :/

* ci: change name
  • Loading branch information
baransu authored Sep 22, 2019
1 parent daeef12 commit 3edc414
Show file tree
Hide file tree
Showing 28 changed files with 384 additions and 460 deletions.
14 changes: 0 additions & 14 deletions .ci/download_binaries.sh

This file was deleted.

28 changes: 0 additions & 28 deletions .ci/wait_for_binaries.sh

This file was deleted.

84 changes: 84 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
name: graphql_ppx_re CI

on: [push]

jobs:
test_and_build:
name: Test on node ${{ matrix.node_version }} and ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
node-version: [12.x]
os: [ubuntu-latest, windows-latest, macOS-latest]

steps:
- uses: actions/checkout@v1
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}

- name: setup
run: |
npm install -g esy@latest cross-env
- name: install
run: |
esy install && cd tests && npm install && cd ../
- name: build
run: |
esy build
- name: test
run: |
cd tests && npm run test && cd ../ && mv _build/default/src/bucklescript_bin/bin.exe graphql_ppx-${{ matrix.os }}.exe
env:
CI: true

- name: Upload artifacts ${{ matrix.os }}
uses: actions/upload-artifact@master
with:
name: graphql_ppx-${{ matrix.os }}.exe
path: graphql_ppx-${{ matrix.os }}.exe

publish:
needs: test_and_build
name: Publish
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1

- name: Download linux artifacts
uses: actions/download-artifact@master
with:
name: graphql_ppx-ubuntu-latest.exe
path: graphql_ppx-linux-x64.exe

- name: Download macOS artifacts
uses: actions/download-artifact@master
with:
name: graphql_ppx-macOS-latest.exe
path: graphql_ppx-darwin-x64.exe

- name: Download windows artifacts
uses: actions/download-artifact@master
with:
name: graphql_ppx-windows-latest.exe
path: graphql_ppx-win-x64.exe

- name: Move artifacts
run: |
mkdir -p bin
mv graphql_ppx-win-x64.exe bin/graphql_ppx-win-x64.exe
mv graphql_ppx-darwin-x64.exe bin/graphql_ppx-darwin-x64.exe
mv graphql_ppx-linux-x64.exe bin/graphql_ppx-linux-x64.exe
- name: Publish
if: github.event_name == 'release' && github.event.action == 'published'
uses: actions/npm@master
env:
NPM_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
with:
args: publish
39 changes: 0 additions & 39 deletions .github/workflows/nodejs.yml

This file was deleted.

67 changes: 0 additions & 67 deletions .travis.yml

This file was deleted.

1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# graphql_ppx_re

[![npm version](https://badge.fury.io/js/%40baransu%2Fgraphql_ppx_re.svg)](https://badge.fury.io/js/%40baransu%2Fgraphql_ppx_re)
[![Build Status](https://travis-ci.com/baransu/graphql_ppx_re.svg?branch=master)](https://travis-ci.com/baransu/graphql_ppx_re)

### [Native Reason and BuckleScript 6.x support is coming!](https://github.com/baransu/graphql_ppx_re/pull/13)

Expand Down
12 changes: 5 additions & 7 deletions esy.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,11 @@
"@opam/ppx_tools_versioned": "*",
"@esy-ocaml/reason": "*",
"refmterr": "*",
"ocaml": "~4.2.3"
"ocaml": "~4.2.3",
"@opam/menhir": "20171013"
},
"devDependencies": {
"@esy-ocaml/merlin": "*",
"ocaml": "~4.2.3"
},
"peerDependencies": {
"ocaml": ">= 4.2.3 < 4.7.0"
"esy": {
"build": "refmterr dune build -p graphql_ppx",
"buildsInSource": "_build"
}
}
Loading

0 comments on commit 3edc414

Please sign in to comment.