Skip to content

Commit

Permalink
refactor!: simplify functor implementation (#27)
Browse files Browse the repository at this point in the history
* chore: simplify functor

* chore: separate format-step

* CI: Don't run tests on windows, temporarily

* Headers were not sent (lwt), separate examples

* CI: Update workflows

* Add more documention for Fetch

* Add credits to Fetch Core

* Only run odoc for core, lwt

* Revert Body.toString returning a Promise.t
  • Loading branch information
lessp authored Mar 30, 2020
1 parent 0774bc9 commit fa326da
Show file tree
Hide file tree
Showing 161 changed files with 1,823 additions and 11,084 deletions.
25 changes: 13 additions & 12 deletions .github/workflows/macos.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: macOS
name: macOS

on:
push:
Expand All @@ -7,21 +7,22 @@ on:

jobs:
build:
runs-on: macOS-latest
runs-on: macOS-latest
steps:
- uses: actions/setup-node@v1
with:
node-version: 12.16.1
- uses: actions/checkout@v1
- name: Install esy
run: npm install -g esy@latest
- name: Build packages
run: |
esy '@fetch-core'
esy '@fetch-native-lwt'
- name: Run esy
run: esy
- name: Run tests
run: esy test
- name: Run example
run: esy example
# Fetch Core
- name: esy '@fetch-core'
run: esy '@fetch-core'
- name: esy '@fetch-core' test
run: esy '@fetch-core' test

# Fetch Native Lwt
- name: esy '@fetch-native-lwt'
run: esy '@fetch-native-lwt'
- name: esy '@fetch-native-lwt' example:get
run: esy '@fetch-native-lwt' example:get
26 changes: 15 additions & 11 deletions .github/workflows/pr_check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,19 @@ jobs:
- uses: actions/checkout@v1
- name: Install esy
run: npm install -g esy@latest
- name: Build packages
run: |
esy '@fetch-core'
esy '@fetch-native-lwt'
- name: Run esy
run: esy

# Fetch Core
- name: esy '@fetch-core'
run: esy '@fetch-core'
- if: matrix.os != 'windows-latest'
run: esy '@fetch-core' test
- if: matrix.os != 'windows-latest'
run: esy '@fetch-core' format

# Fetch Native Lwt
- name: esy '@fetch-native-lwt'
run: esy '@fetch-native-lwt'
- if: matrix.os != 'windows-latest'
run: esy dune build @fmt --root .
- name: Run tests
run: esy test
- name: Run example
run: esy example
run: esy '@fetch-native-lwt' format
- name: esy '@fetch-native-lwt' example:get
run: esy '@fetch-native-lwt' example:get
25 changes: 13 additions & 12 deletions .github/workflows/ubuntu.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Ubuntu
name: Ubuntu

on:
push:
Expand All @@ -7,21 +7,22 @@ on:

jobs:
build:
runs-on: ubuntu-latest
runs-on: ubuntu-latest
steps:
- uses: actions/setup-node@v1
with:
node-version: 12.16.1
- uses: actions/checkout@v1
- name: Install esy
run: npm install -g esy@latest
- name: Build packages
run: |
esy '@fetch-core'
esy '@fetch-native-lwt'
- name: Run esy
run: esy
- name: Run tests
run: esy test
- name: Run example
run: esy example
# Fetch Core
- name: esy '@fetch-core'
run: esy '@fetch-core'
- name: esy '@fetch-core' test
run: esy '@fetch-core' test

# Fetch Native Lwt
- name: esy '@fetch-native-lwt'
run: esy '@fetch-native-lwt'
- name: esy '@fetch-native-lwt' example:get
run: esy '@fetch-native-lwt' example:get
25 changes: 13 additions & 12 deletions .github/workflows/windows.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Windows
name: Windows

on:
push:
Expand All @@ -7,21 +7,22 @@ on:

jobs:
build:
runs-on: windows-latest
runs-on: windows-latest
steps:
- uses: actions/setup-node@v1
with:
node-version: 12.16.1
- uses: actions/checkout@v1
- name: Install esy
run: npm install -g esy@latest
- name: Build packages
run: |
esy '@fetch-core'
esy '@fetch-native-lwt'
- name: Run esy
run: esy
- name: Run tests
run: esy test
- name: Run example
run: esy example
# Fetch Core
- name: esy '@fetch-core'
run: esy '@fetch-core'
- name: esy '@fetch-core' test
run: esy '@fetch-core' test

# Fetch Native Lwt
- name: esy '@fetch-native-lwt'
run: esy '@fetch-native-lwt'
- name: esy '@fetch-native-lwt' example:get
run: esy '@fetch-native-lwt' example:get
3 changes: 3 additions & 0 deletions dune
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
(dirs :standard \ fetch-js)

;; include all directories except fetch-js
3 changes: 1 addition & 2 deletions dune-project
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
(lang dune 1.11)
(lang dune 2.0)
(name fetch)
(using fmt 1.2)
File renamed without changes.
3 changes: 0 additions & 3 deletions esy.lock/.gitattributes

This file was deleted.

3 changes: 0 additions & 3 deletions esy.lock/.gitignore

This file was deleted.

Loading

0 comments on commit fa326da

Please sign in to comment.