-
Notifications
You must be signed in to change notification settings - Fork 15
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
Work with fsevents/cf libs #31
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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,34 @@ | ||
name: Main workflow | ||
|
||
on: | ||
- pull_request | ||
- push | ||
|
||
jobs: | ||
build: | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: | ||
- macos-latest | ||
ocaml-version: | ||
- 4.12.0 | ||
- 4.11.1 | ||
- 4.10.2 | ||
- 4.09.1 | ||
- 4.08.1 | ||
|
||
runs-on: ${{ matrix.os }} | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v2 | ||
- name: Use OCaml ${{ matrix.ocaml-version }} | ||
uses: avsm/setup-ocaml@v1 | ||
with: | ||
ocaml-version: ${{ matrix.ocaml-version }} | ||
- run: opam pin add . --no-action | ||
- run: opam depext irmin-watcher --yes --with-doc --with-test | ||
- run: opam install . --deps-only --with-doc --with-test | ||
- run: opam exec -- dune build | ||
- run: opam exec -- dune runtest |
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,4 @@ | ||
version = 0.14.2 | ||
version = 0.18.0 | ||
break-infix = fit-or-vertical | ||
parse-docstrings = true | ||
indicate-multiline-delimiters = no |
This file was deleted.
Oops, something went wrong.
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
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 | ||||
---|---|---|---|---|---|---|
|
@@ -8,7 +8,7 @@ bug-reports: "https://github.com/mirage/irmin-watcher/issues" | |||||
license: "ISC" | ||||||
|
||||||
build: [ | ||||||
["dune" "subst"] {pinned} | ||||||
["dune" "subst"] {dev} | ||||||
["dune" "build" "-p" name "-j" jobs] | ||||||
] | ||||||
|
||||||
|
@@ -23,16 +23,24 @@ depends: [ | |||||
"logs" | ||||||
"fmt" | ||||||
"astring" | ||||||
"inotify" {os = "linux"} | ||||||
"osx-fsevents" {os = "macos" & >= "0.2.0"} | ||||||
"inotify" {os = "linux"} | ||||||
"cf-lwt" | ||||||
"fsevents-lwt" | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
] | ||||||
|
||||||
synopsis: "Portable Irmin watch backends using FSevents or Inotify" | ||||||
description: """ | ||||||
irmin-watcher implements [Irmin's watch hooks][watch] for various OS, | ||||||
using FSevents in OSX and Inotify on Linux. | ||||||
using FSevents in macOS and Inotify on Linux. | ||||||
|
||||||
irmin-watcher is distributed under the ISC license. | ||||||
|
||||||
[watch]: http://mirage.github.io/irmin/irmin/Irmin/Private/Watch/index.html#type-hook | ||||||
""" | ||||||
|
||||||
pin-depends: [ | ||||||
[ "fsevents.dev" "git+https://github.com/mirage/ocaml-fsevents.git#f9e797e16bdbc730804cd684f07808022495c333" ] | ||||||
[ "fsevents-lwt.dev" "git+https://github.com/mirage/ocaml-fsevents.git#f9e797e16bdbc730804cd684f07808022495c333" ] | ||||||
[ "cf.dev" "git+https://github.com/mirage/ocaml-cf.git#918e2b9a7ab6871e48cce0508bce5e45981375f6" ] | ||||||
[ "cf-lwt.dev" "git+https://github.com/mirage/ocaml-cf.git#918e2b9a7ab6871e48cce0508bce5e45981375f6" ] | ||||||
] |
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
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
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
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
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
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
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
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
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,3 +1,9 @@ | ||
(test | ||
(executable | ||
(name test) | ||
(libraries alcotest logs.fmt irmin-watcher mtime mtime.clock.os)) | ||
|
||
(rule | ||
(alias runtest) | ||
(deps test.exe) | ||
(action | ||
(run ./test.exe -q --color=always))) |
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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
actually not needed any more -- I modified the dependent libraries to be optional but installable on Linux, so it'll work in a duniverse. So they can be firm dependencies now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's better to not force these dependencies if possible (to avoid future compilation issues on Linux due to unrelated issues on macos).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we need it to work in a duniverse though. The non-macOS builds don't do anything on Linux at all -- i used
enabled_if
to just not compile them when system <> macOS. https://github.com/mirage/ocaml-cf/blob/main/lib/dune#L7So the whole dependency should be a noop if os != macos (but it will jsut work if irmin-watcher is cloned into a duniverse and compiled on a mac)