-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
231b87a
commit c3de9ba
Showing
120 changed files
with
7,397 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,162 @@ | ||
version: 2 | ||
|
||
common_cache_key: &common_cache_key | ||
key: dependency-cache-{{ checksum "../ocaml-version" }}-{{ checksum ".circleci/config.yml" }}-{{ checksum "websocketaf.opam" }}-{{ checksum "websocketaf-async.opam" }}-{{ checksum "websocketaf-lwt.opam" }}-{{ checksum "websocketaf-lwt.opam" }} | ||
|
||
esy_cache_key: &esy_cache_key | ||
key: esy-cache-{{ checksum "esy.json" }}-{{ checksum "../esy-checksum" }}-{{ checksum ".circleci/config.yml" }} | ||
|
||
esy_post_build_cache_key: &esy_post_build_cache_key | ||
key: esy-post-build-cache-{{ checksum "esy.json" }}-{{ checksum "../esy-checksum" }}-{{ checksum ".circleci/config.yml" }} | ||
|
||
opam-steps: &opam-steps | ||
steps: | ||
- checkout | ||
- run: | ||
name: "Pull Submodules" | ||
command: git submodule update --init --recursive | ||
- run: | ||
name: "Note OCAML_VERSION for cache" | ||
command: echo $OCAML_VERSION > ../ocaml-version | ||
- restore_cache: | ||
<<: *common_cache_key | ||
- run: | ||
name: "Initialize opam" | ||
command: | | ||
sudo apt-get install -y m4 | ||
opam init --auto-setup --dot-profile=~/.bash_profile | ||
opam remote add ocamlorg https://opam.ocaml.org || true | ||
opam remote remove default || true | ||
- run: | ||
name: "Install deps" | ||
command: | | ||
sudo apt-get install -y pkg-config libgmp-dev autotools-dev autoconf lsof libssl-dev | ||
opam update | ||
opam install -y dune | ||
opam pin add httpaf git+https://github.com/anmonteiro/httpaf#fork | ||
opam pin add httpaf-lwt git+https://github.com/anmonteiro/httpaf#fork | ||
opam pin add httpaf-lwt-unix git+https://github.com/anmonteiro/httpaf#fork | ||
opam pin add httpaf-async git+https://github.com/anmonteiro/httpaf#fork | ||
opam install -t --deps-only . | ||
- run: | ||
name: 'Clean' | ||
command: rm -rf ./_build | ||
- save_cache: | ||
<<: *common_cache_key | ||
paths: | ||
- ~/.opam | ||
- run: | ||
name: 'Test' | ||
command: | | ||
eval `opam config env` | ||
dune build @all | ||
dune runtest --no-buffer | ||
- run: | ||
name: 'Check git is clean' | ||
command: git diff --exit-code | ||
|
||
jobs: | ||
4.04.2: | ||
docker: | ||
- image: ocaml/opam2:debian-9-ocaml-4.04 | ||
environment: | ||
- TERM: dumb | ||
- OCAML_VERSION: "4.04.2" | ||
- OPAMSOLVERTIMEOUT: "360" | ||
<<: *opam-steps | ||
4.05.0: | ||
docker: | ||
- image: ocaml/opam2:debian-9-ocaml-4.05 | ||
environment: | ||
- TERM: dumb | ||
- OCAML_VERSION: "4.05.0" | ||
<<: *opam-steps | ||
4.06.1: | ||
docker: | ||
- image: ocaml/opam2:debian-9-ocaml-4.06 | ||
environment: | ||
- TERM: dumb | ||
- OCAML_VERSION: "4.06.1" | ||
<<: *opam-steps | ||
4.07.1: | ||
docker: | ||
- image: ocaml/opam2:debian-9-ocaml-4.07 | ||
environment: | ||
- TERM: dumb | ||
- OCAML_VERSION: "4.07.1" | ||
<<: *opam-steps | ||
esy: | ||
docker: | ||
- image: circleci/node:11.9 | ||
environment: | ||
- TERM: dumb | ||
- NPM_CONFIG_PREFIX: "~/.npm-global" | ||
steps: | ||
- checkout | ||
- run: | ||
name: "Pull Submodules" | ||
command: git submodule update --init --recursive | ||
- run: | ||
name: 'Note esy.lock checksum for cache' | ||
command: find esy.lock -type f -exec md5sum {} \; | sort -k 2 | md5sum > ../esy-checksum | ||
- restore_cache: | ||
<<: *esy_cache_key | ||
- restore_cache: | ||
<<: *esy_post_build_cache_key | ||
- run: | ||
name: "Install esy + system deps" | ||
command: | | ||
sudo apt-get install texinfo autotools-dev autoconf | ||
npm install -g esy | ||
- run: | ||
name: 'esy install' | ||
command: ~/.npm-global/bin/esy install | ||
- save_cache: | ||
<<: *esy_cache_key | ||
paths: | ||
- ~/.npm-global | ||
- ~/.esy | ||
- run: | ||
name: 'esy build' | ||
command: ~/.npm-global/bin/esy b dune build @all | ||
- run: | ||
name: 'esy test' | ||
command: ~/.npm-global/bin/esy b dune runtest --no-buffer | ||
# Use both pre and post build caches so that we're more likely | ||
# to have dependencies cached. `esy build` is more likely to fail, | ||
# so this will make the push that fixes the build faster | ||
- save_cache: | ||
<<: *esy_post_build_cache_key | ||
paths: | ||
- ~/.esy | ||
- node_modules | ||
|
||
workflows: | ||
version: 2 | ||
build-deploy: | ||
jobs: | ||
- 4.04.2: | ||
filters: | ||
branches: | ||
ignore: | ||
- gh-pages | ||
- 4.05.0: | ||
filters: | ||
branches: | ||
ignore: | ||
- gh-pages | ||
- 4.06.1: | ||
filters: | ||
branches: | ||
ignore: | ||
- gh-pages | ||
- 4.07.1: | ||
filters: | ||
branches: | ||
ignore: | ||
- gh-pages | ||
- esy: | ||
filters: | ||
branches: | ||
ignore: | ||
- gh-pages |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,3 +7,5 @@ lib_test/tests_ | |
*.docdir | ||
.merlin | ||
*.install | ||
node_modules | ||
_esy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
(library | ||
(name websocketaf_async) | ||
(name websocketaf_async) | ||
(public_name websocketaf-async) | ||
(libraries | ||
async core angstrom-async faraday-async websocketaf digestif.ocaml base64) | ||
(flags (:standard -safe-string))) | ||
(libraries async core faraday-async websocketaf digestif.ocaml base64) | ||
(flags | ||
(:standard -safe-string))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
open! Core | ||
open Async | ||
|
||
module Client : sig | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
{ | ||
"name": "websocketaf", | ||
"version": "0.1.0", | ||
"license": "BSD-3-clause", | ||
"repository": "git+https://github.com/anmonteiro/websocketaf", | ||
"dependencies": { | ||
"ocaml": "4.8.0", | ||
"@opam/dune": "*", | ||
"@opam/lwt": "*", | ||
"@opam/bigstringaf": "*", | ||
"@opam/angstrom": "*", | ||
"@opam/faraday": "*", | ||
"@opam/faraday-async": "*", | ||
"@opam/faraday-lwt-unix": "*", | ||
"@opam/async": "*", | ||
"@opam/httpaf": "*", | ||
"@opam/httpaf-lwt": "*", | ||
"@opam/httpaf-lwt-unix": "*", | ||
"@opam/httpaf-async": "*", | ||
"@opam/base64": "*", | ||
"@opam/digestif": "*" | ||
}, | ||
"devDependencies": { | ||
"@opam/alcotest": "*", | ||
"@opam/merlin": "*", | ||
"@opam/odoc": "*" | ||
}, | ||
"resolutions": { | ||
"@opam/conf-openssl": "esy-packages/esy-openssl#dafe9ad", | ||
"@opam/httpaf": "anmonteiro/httpaf:httpaf.opam#372c376", | ||
"@opam/httpaf-lwt": "anmonteiro/httpaf:httpaf-lwt.opam#372c376", | ||
"@opam/httpaf-lwt-unix": "anmonteiro/httpaf:httpaf-lwt-unix.opam#372c376", | ||
"@opam/httpaf-async": "anmonteiro/httpaf:httpaf-async.opam#372c376" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
|
||
# Set eol to LF so files aren't converted to CRLF-eol on Windows. | ||
* text eol=lf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
|
||
# Reset any possible .gitignore, we want all esy.lock to be un-ignored. | ||
!* |
Oops, something went wrong.