Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mini conduit in Git #428

Merged
merged 28 commits into from
Jan 5, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
6ae3a2d
Small re-impl. of Conduit 3.0.0 inside Git
dinosaure Dec 19, 2020
52ee9bf
A simple module to move from Mirage_flow.S to something which is more…
dinosaure Dec 19, 2020
c7a966d
Update not-so-smart libraries with mimic
dinosaure Dec 19, 2020
5be6187
Upgrade to the Mimic context
dinosaure Dec 19, 2020
5acfb50
Slight update on tests
dinosaure Dec 19, 2020
a5f6a12
Slight update on git-unix
dinosaure Dec 19, 2020
7c719ed
Slight update on git-cohttp (use cohttp.2.5.4)
dinosaure Dec 19, 2020
3bde0d8
Lint on OPAM files
dinosaure Dec 19, 2020
aad17b6
Delete pin-depends
dinosaure Dec 19, 2020
e39ca69
Add a pin-depends on awa
dinosaure Dec 19, 2020
d65b92a
Support SSH
dinosaure Dec 19, 2020
afc188b
Update Travis CI and AppVeyor CI
dinosaure Dec 19, 2020
b897254
Apply ocamlformat.0.16.0
dinosaure Dec 19, 2020
db699f1
Add mimic as a dependency of git-nss
dinosaure Dec 20, 2020
bde6d4c
Handle redirections with CoHTTP (only for git-unix)
dinosaure Jan 4, 2021
6c3d3d0
Handle redirections and allow a Conduit value given by the Mimic ctx
dinosaure Jan 4, 2021
9fd86f9
Add topological sort, priorities and merge function
dinosaure Jan 4, 2021
415fdd0
Pass the Mimic ctx to the HTTP implementation and minor update about …
dinosaure Jan 4, 2021
36e94b9
Add is_ssh argument to recognize an SSH communication
dinosaure Jan 4, 2021
60f1442
Update tests with is_ssh arguments
dinosaure Jan 4, 2021
2958aae
Lint OPAM files
dinosaure Jan 4, 2021
a1ca912
Add functors to make Mimic ctx
dinosaure Jan 4, 2021
5b79548
Add an example about MirageOS and ocaml-git
dinosaure Jan 4, 2021
23f5b4e
Add some tests about mimic library
dinosaure Jan 2, 2021
7e44c23
Compatibility with old version of Cstruct
dinosaure Jan 4, 2021
2f73b76
Add test about MirageOS and ocaml-git
dinosaure Jan 4, 2021
cc1002f
Add some others tests about mimic (topological sort, orders, etc.)
dinosaure Jan 4, 2021
9c75798
Mirage_protocol.connect returns a write error to follow tls-mirage
dinosaure Jan 5, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .test-mirage.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/bin/sh

set -ex

opam install -y mirage
(cd unikernel && mirage configure -t unix && make depends && mirage build && mirage clean && cd ..) || exit 1
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ install: wget https://raw.githubusercontent.com/ocaml/ocaml-ci-scripts/master/.t
script: bash -ex .travis-opam.sh
env:
global:
- PINS="carton.dev:. carton-lwt.dev:. carton-git.dev:. git-nss.dev:. git.dev:. git-unix.dev:. git-cohttp.dev:. git-cohttp-unix.dev:."
- PINS="mimic.dev:. carton.dev:. carton-lwt.dev:. carton-git.dev:. git-nss.dev:. git.dev:. git-unix.dev:. git-cohttp.dev:. git-cohttp-unix.dev:."
matrix:
- OCAML_VERSION=4.08 PACKAGE="git.dev"
- OCAML_VERSION=4.09 PACKAGE="git.dev"
Expand Down
2 changes: 1 addition & 1 deletion appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ environment:
FORK_BRANCH: master
CYG_ROOT: C:\cygwin64
OPAM_SWITCH: 4.08.1+mingw64c
PINS: "carton.dev:. carton-lwt.dev:. carton-git.dev:. git-nss.dev:. git.dev:. git-cohttp.dev:. git-cohttp-unix.dev:. git-unix.dev:."
PINS: "mimic.dev:. carton.dev:. carton-lwt.dev:. carton-git.dev:. git-nss.dev:. git.dev:. git-cohttp.dev:. git-cohttp-unix.dev:. git-unix.dev:."
matrix:
- PACKAGE: "git.dev"
- PACKAGE: "git-unix.dev"
Expand Down
47 changes: 26 additions & 21 deletions carton-git.opam
Original file line number Diff line number Diff line change
@@ -1,26 +1,19 @@
opam-version: "2.0"
name: "carton"
maintainer: "Romain Calascibetta <[email protected]>"
authors: "Romain Calascibetta <[email protected]>"
homepage: "https://github.com/dinosaure/carton"
bug-reports: "https://github.com/dinosaure/carton/issues"
dev-repo: "git+https://github.com/dinosaure/carton.git"
doc: "https://dinosaure.github.io/carton/"
license: "MIT"
synopsis: "Implementation of PACK file in OCaml"
description: """Carton is an implementation of the PACK file
name: "carton"
synopsis: "Implementation of PACK file in OCaml"
description: """\
Carton is an implementation of the PACK file
in OCaml. PACK file is used by Git to store Git objects. Carton is more
abstracted when it can store any objects.
"""

build: [
[ "dune" "build" "-p" name "-j" jobs ]
[ "dune" "runtest" "-p" name "-j" jobs ] {with-test}
]

abstracted when it can store any objects."""
maintainer: "Romain Calascibetta <[email protected]>"
authors: "Romain Calascibetta <[email protected]>"
license: "MIT"
homepage: "https://github.com/dinosaure/carton"
doc: "https://dinosaure.github.io/carton/"
bug-reports: "https://github.com/dinosaure/carton/issues"
depends: [
"ocaml" {>= "4.07.0"}
"dune" {>= "2.6.0"}
"ocaml" {>= "4.07.0"}
"dune" {>= "2.6.0"}
"carton"
"carton-lwt"
"bigarray-compat"
Expand All @@ -29,7 +22,19 @@ depends: [
"fpath"
"result"
"mmap"
"fmt" {>= "0.8.7"}
"fmt" {>= "0.8.7"}
"base-unix"
"decompress" {>= "1.2.0"}
"astring" {>= "0.8.5"}
"alcotest" {>= "1.2.3" & with-test}
"alcotest-lwt" {>= "1.2.3" & with-test}
"cstruct" {>= "6.0.0" & with-test}
"logs" {>= "0.7.0" & with-test}
"mirage-flow" {>= "2.0.1" & with-test}
"rresult" {>= "0.6.0" & with-test}
]
build: [
["dune" "build" "-p" name "-j" jobs]
["dune" "runtest" "-p" name "-j" jobs] {with-test}
]
dev-repo: "git+https://github.com/dinosaure/carton.git"
48 changes: 27 additions & 21 deletions carton-lwt.opam
Original file line number Diff line number Diff line change
@@ -1,29 +1,35 @@
opam-version: "2.0"
name: "carton"
maintainer: "Romain Calascibetta <[email protected]>"
authors: "Romain Calascibetta <[email protected]>"
homepage: "https://github.com/dinosaure/carton"
bug-reports: "https://github.com/dinosaure/carton/issues"
dev-repo: "git+https://github.com/dinosaure/carton.git"
doc: "https://dinosaure.github.io/carton/"
license: "MIT"
synopsis: "Implementation of PACK file in OCaml"
description: """Carton is an implementation of the PACK file
name: "carton"
synopsis: "Implementation of PACK file in OCaml"
description: """\
Carton is an implementation of the PACK file
in OCaml. PACK file is used by Git to store Git objects. Carton is more
abstracted when it can store any objects.
"""

build: [
[ "dune" "build" "-p" name "-j" jobs ]
[ "dune" "runtest" "-p" name "-j" jobs ] {with-test}
]

abstracted when it can store any objects."""
maintainer: "Romain Calascibetta <[email protected]>"
authors: "Romain Calascibetta <[email protected]>"
license: "MIT"
homepage: "https://github.com/dinosaure/carton"
doc: "https://dinosaure.github.io/carton/"
bug-reports: "https://github.com/dinosaure/carton/issues"
depends: [
"ocaml" {>= "4.07.0"}
"dune" {>= "2.6.0"}
"ocaml" {>= "4.07.0"}
"dune" {>= "2.6.0"}
"carton"
"lwt"
"decompress" {>= "1.2.0"}
"optint" {>= "0.0.4"}
"optint" {>= "0.0.4"}
"bigstringaf"
"alcotest" {>= "1.2.3" & with-test}
"alcotest-lwt" {>= "1.2.3" & with-test}
"cstruct" {>= "6.0.0" & with-test}
"fmt" {>= "0.8.9" & with-test}
"logs" {>= "0.7.0" & with-test}
"mirage-flow" {>= "2.0.1" & with-test}
"result" {>= "1.5" & with-test}
"rresult" {>= "0.6.0" & with-test}
]
build: [
["dune" "build" "-p" name "-j" jobs]
["dune" "runtest" "-p" name "-j" jobs] {with-test}
]
dev-repo: "git+https://github.com/dinosaure/carton.git"
78 changes: 40 additions & 38 deletions carton.opam
Original file line number Diff line number Diff line change
@@ -1,48 +1,50 @@
opam-version: "2.0"
name: "carton"
maintainer: "Romain Calascibetta <[email protected]>"
authors: "Romain Calascibetta <[email protected]>"
homepage: "https://github.com/mirage/ocaml-git"
bug-reports: "https://github.com/mirage/ocaml-git/issues"
dev-repo: "git+https://github.com/mirage/ocaml-git.git"
doc: "https://mirage.github.io/ocaml-git/"
license: "MIT"
synopsis: "Implementation of PACKv2 file in OCaml"
description: """Carton is an implementation of the PACKv2 file
name: "carton"
synopsis: "Implementation of PACKv2 file in OCaml"
description: """\
Carton is an implementation of the PACKv2 file
in OCaml. PACKv2 file is used by Git to store Git objects.
Carton is more abstracted when it can store any objects.
"""

build: [
[ "dune" "build" "-p" name "-j" jobs ]
[ "dune" "runtest" "-p" name "-j" jobs ] {with-test}
]

Carton is more abstracted when it can store any objects."""
maintainer: "Romain Calascibetta <[email protected]>"
authors: "Romain Calascibetta <[email protected]>"
license: "MIT"
homepage: "https://github.com/mirage/ocaml-git"
doc: "https://mirage.github.io/ocaml-git/"
bug-reports: "https://github.com/mirage/ocaml-git/issues"
depends: [
"ocaml" {>= "4.07.0"}
"dune" {>= "2.6.0"}
"ke" {>= "0.4"}
"duff" {>= "0.3"}
"decompress" {>= "1.2.0"}
"cstruct" {>= "5.0.0"}
"optint" {>= "0.0.4"}
"ocaml" {>= "4.07.0"}
"dune" {>= "2.6.0"}
"ke" {>= "0.4"}
"duff" {>= "0.3"}
"decompress" {>= "1.2.0"}
"cstruct" {>= "5.0.0"}
"optint" {>= "0.0.4"}
"bigstringaf"
"stdlib-shims"
"bigarray-compat"
"checkseum" {>= "0.2.1"}
"checkseum" {>= "0.2.1"}
"logs"
"bigstringaf"
"psq" {>= "0.2.0"}
"fmt" {>= "0.8.7"}
"result" {with-test}
"rresult" {with-test}
"fpath" {with-test}
"base64" {with-test & >= "3.0.0"}
"bos" {with-test}
"digestif" {with-test & >= "0.8.1"}
"mmap" {with-test}
"base-unix" {with-test}
"psq" {>= "0.2.0"}
"fmt" {>= "0.8.7"}
"result" {with-test}
"rresult" {with-test}
"fpath" {with-test}
"base64" {with-test & >= "3.0.0"}
"bos" {with-test}
"digestif" {with-test & >= "0.8.1"}
"mmap" {with-test}
"base-unix" {with-test}
"base-threads" {with-test}
"alcotest" {with-test}
"crowbar" {with-test & >= "0.2"}
"alcotest" {with-test}
"crowbar" {with-test & >= "0.2"}
"alcotest-lwt" {>= "1.2.3" & with-test}
"lwt" {>= "5.3.0" & with-test}
"ocamlfind" {>= "1.8.1" & with-test}
"mirage-flow" {>= "2.0.1" & with-test}
]
build: [
["dune" "build" "-p" name "-j" jobs]
["dune" "runtest" "-p" name "-j" jobs] {with-test}
]
dev-repo: "git+https://github.com/mirage/ocaml-git.git"
55 changes: 28 additions & 27 deletions git-cohttp-mirage.opam
Original file line number Diff line number Diff line change
@@ -1,33 +1,34 @@
opam-version: "2.0"
maintainer: [ "[email protected]"
"[email protected]" ]
authors: "Thomas Gazagnaire"
license: "ISC"
homepage: "https://github.com/mirage/ocaml-git"
bug-reports: "https://github.com/mirage/ocaml-git/issues"
dev-repo: "git+https://github.com/mirage/ocaml-git.git"
doc: "https://mirage.github.io/ocaml-git/"
synopsis: "A package to use HTTP-based ocaml-git with MirageOS backend"

build: [
["dune" "subst"]
["dune" "build" "-p" name "-j" jobs]
["dune" "runtest" "-p" name "-j1" "--no-buffer"] {with-test}
]

synopsis: "A package to use HTTP-based ocaml-git with MirageOS backend"
maintainer: ["[email protected]" "[email protected]"]
authors: "Thomas Gazagnaire"
license: "ISC"
homepage: "https://github.com/mirage/ocaml-git"
doc: "https://mirage.github.io/ocaml-git/"
bug-reports: "https://github.com/mirage/ocaml-git/issues"
depends: [
"ocaml" {>= "4.07.0"}
"dune" {>= "2.6.0"}
"ocaml" {>= "4.07.0"}
"dune" {>= "2.6.0"}
"git"
"git-cohttp"
"mimic"
"cohttp-mirage"
"cohttp" {>= "2.5.4"}
"cohttp-lwt" {>= "2.5.4"}
"fmt" {>= "0.8.9"}
"lwt" {>= "5.3.0"}
"result" {>= "1.5"}
"rresult" {>= "0.6.0"}
"uri" {>= "4.0.0"}
"alcotest" {>= "1.2.3" & with-test}
"alcotest-lwt" {>= "1.2.3" & with-test}
"bigstringaf" {>= "0.7.0" & with-test}
"cstruct" {>= "6.0.0" & with-test}
"logs" {>= "0.7.0" & with-test}
"mirage-flow" {>= "2.0.1" & with-test}
]

pin-depends: [
[ "conduit.dev" "git+https://github.com/mirage/ocaml-conduit.git#8912d458b2f3e43245e99cf3cb74e9c00712a8b0" ]
[ "conduit-tls.dev" "git+https://github.com/mirage/ocaml-conduit.git#8912d458b2f3e43245e99cf3cb74e9c00712a8b0" ]
[ "conduit-mirage.dev" "git+https://github.com/mirage/ocaml-conduit.git#8912d458b2f3e43245e99cf3cb74e9c00712a8b0" ]
[ "cohttp.dev" "git+https://github.com/dinosaure/ocaml-cohttp.git#7f0efc6d7e0420e3abff99d29633519785c41f4b" ]
[ "cohttp-lwt.dev" "git+https://github.com/dinosaure/ocaml-cohttp.git#7f0efc6d7e0420e3abff99d29633519785c41f4b" ]
[ "cohttp-mirage.dev" "git+https://github.com/dinosaure/ocaml-cohttp.git#7f0efc6d7e0420e3abff99d29633519785c41f4b" ]
build: [
["dune" "subst"]
["dune" "build" "-p" name "-j" jobs]
["dune" "runtest" "-p" name "-j1" "--no-buffer"] {with-test}
]
dev-repo: "git+https://github.com/mirage/ocaml-git.git"
54 changes: 27 additions & 27 deletions git-cohttp-unix.opam
Original file line number Diff line number Diff line change
@@ -1,34 +1,34 @@
opam-version: "2.0"
maintainer: [ "[email protected]"
"[email protected]" ]
authors: "Thomas Gazagnaire"
license: "ISC"
homepage: "https://github.com/mirage/ocaml-git"
bug-reports: "https://github.com/mirage/ocaml-git/issues"
dev-repo: "git+https://github.com/mirage/ocaml-git.git"
doc: "https://mirage.github.io/ocaml-git/"
synopsis: "A package to use HTTP-based ocaml-git with Unix backend"

build: [
["dune" "subst"]
["dune" "build" "-p" name "-j" jobs]
["dune" "runtest" "-p" name "-j1" "--no-buffer"] {with-test}
]

synopsis: "A package to use HTTP-based ocaml-git with Unix backend"
maintainer: ["[email protected]" "[email protected]"]
authors: "Thomas Gazagnaire"
license: "ISC"
homepage: "https://github.com/mirage/ocaml-git"
doc: "https://mirage.github.io/ocaml-git/"
bug-reports: "https://github.com/mirage/ocaml-git/issues"
depends: [
"ocaml" {>= "4.07.0"}
"dune" {>= "2.6.0"}
"ocaml" {>= "4.07.0"}
"dune" {>= "2.6.0"}
"git"
"git-cohttp"
"cohttp-lwt-unix"
"cohttp" {>= "2.5.4"}
"cohttp-lwt" {>= "2.5.4"}
"fmt" {>= "0.8.9"}
"lwt" {>= "5.3.0"}
"result" {>= "1.5"}
"rresult" {>= "0.6.0"}
"uri" {>= "4.0.0"}
"alcotest" {>= "1.2.3" & with-test}
"alcotest-lwt" {>= "1.2.3" & with-test}
"bigstringaf" {>= "0.7.0" & with-test}
"cstruct" {>= "6.0.0" & with-test}
"logs" {>= "0.7.0" & with-test}
"mirage-flow" {>= "2.0.1" & with-test}
]

pin-depends: [
[ "conduit.dev" "git+https://github.com/mirage/ocaml-conduit.git#8912d458b2f3e43245e99cf3cb74e9c00712a8b0" ]
[ "conduit-tls.dev" "git+https://github.com/mirage/ocaml-conduit.git#8912d458b2f3e43245e99cf3cb74e9c00712a8b0" ]
[ "conduit-lwt.dev" "git+https://github.com/mirage/ocaml-conduit.git#8912d458b2f3e43245e99cf3cb74e9c00712a8b0" ]
[ "conduit-lwt-tls.dev" "git+https://github.com/mirage/ocaml-conduit.git#8912d458b2f3e43245e99cf3cb74e9c00712a8b0" ]
[ "cohttp.dev" "git+https://github.com/dinosaure/ocaml-cohttp.git#7f0efc6d7e0420e3abff99d29633519785c41f4b" ]
[ "cohttp-lwt.dev" "git+https://github.com/dinosaure/ocaml-cohttp.git#7f0efc6d7e0420e3abff99d29633519785c41f4b" ]
[ "cohttp-lwt-unix.dev" "git+https://github.com/dinosaure/ocaml-cohttp.git#7f0efc6d7e0420e3abff99d29633519785c41f4b" ]
build: [
["dune" "subst"]
["dune" "build" "-p" name "-j" jobs]
["dune" "runtest" "-p" name "-j1" "--no-buffer"] {with-test}
]
dev-repo: "git+https://github.com/mirage/ocaml-git.git"
Loading