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

Some fixes to events #89

Merged
merged 2 commits into from
Sep 12, 2023
Merged

Conversation

arvidj
Copy link
Collaborator

@arvidj arvidj commented Aug 30, 2023

No description provided.

@tmcgilchrist
Copy link
Owner

Small change to cli/user.ml required to consume the new event stream:

-      User.events ~token:config.token ~id () >|~ fun events ->
-      printf "%s\n" (Yojson.Basic.prettify @@ Gitlab_j.string_of_events events)
+
+      let* events =
+        return @@ User.events ~token:config.token ~id ()
+      in
+      Stream.iter
+        (fun event ->
+          return @@ printf "%s\n" (Yojson.Basic.prettify @@ Gitlab_j.string_of_event event))
+        events

@arvidj
Copy link
Collaborator Author

arvidj commented Sep 11, 2023

Small change to cli/user.ml required to consume the new event stream:

Oups, missed that. Fixed in the latest version. I had also forgotten to run ocaml-format.

@tmcgilchrist tmcgilchrist merged commit 770383b into tmcgilchrist:master Sep 12, 2023
9 of 10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants