From a125cb5da389300b3f9e5839dc9ec56b8004ae29 Mon Sep 17 00:00:00 2001 From: Henry Lee Date: Tue, 2 Jun 2026 07:47:40 +0000 Subject: [PATCH 1/4] docs: add opam pin installation instructions Document how to install scribe via `opam pin` against a Git tag, in preparation for the v0.1.0 release. scribe is not published to the opam repository; pinning the tag is the supported installation path. Co-Authored-By: Claude Opus 4.8 --- README.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/README.md b/README.md index 5a84e39..5309a55 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,29 @@ `scribe` is a small structured logging library for OCaml. A logger is an ordinary value that carries its level, sink, and context fields, so application code can compose loggers and library code can accept `?logger` without touching process-wide logging state. +## Installation + +`scribe` is distributed through Git tags; pin it with opam. + +Pin the latest release: + +```sh +LATEST=$(git ls-remote --tags --refs --sort=-v:refname https://github.com/sambyeol/scribe.git | head -n1 | sed 's|.*/||') +opam pin add scribe "https://github.com/sambyeol/scribe.git#$LATEST" +``` + +Or pin a specific version: + +```sh +opam pin add scribe "https://github.com/sambyeol/scribe.git#v0.1.0" +``` + +Then depend on the libraries from your dune file: + +```lisp +(libraries scribe scribe.sinks) +``` + ## Quick Start Use the core logger with the JSON adapter: From 4c4934b01aa6e87121bc5849f089eab01a91cc46 Mon Sep 17 00:00:00 2001 From: Henry Lee Date: Tue, 2 Jun 2026 07:52:26 +0000 Subject: [PATCH 2/4] chore: set package version to 0.1.0 Add `(version 0.1.0)` to dune-project and regenerate scribe.opam so the package reports version 0.1.0 (instead of the pin default ~dev) when installed via `opam pin`. This keeps downstream version constraints such as `(scribe (>= 0.1.0))` satisfiable. Co-Authored-By: Claude Opus 4.8 --- dune-project | 2 ++ scribe.opam | 1 + 2 files changed, 3 insertions(+) diff --git a/dune-project b/dune-project index 17d2322..a51483b 100644 --- a/dune-project +++ b/dune-project @@ -2,6 +2,8 @@ (name scribe) +(version 0.1.0) + (generate_opam_files true) (source diff --git a/scribe.opam b/scribe.opam index 4c22dbb..7a22d61 100644 --- a/scribe.opam +++ b/scribe.opam @@ -1,5 +1,6 @@ # This file is generated by dune, edit dune-project instead opam-version: "2.0" +version: "0.1.0" synopsis: "Value-based structured logging for OCaml" description: "Scribe is a small structured logging library whose logger values carry their level, sink, and context." From d869c88faea5755d8ce5c4285498a018f19e92b7 Mon Sep 17 00:00:00 2001 From: Henry Lee Date: Tue, 2 Jun 2026 07:54:04 +0000 Subject: [PATCH 3/4] docs: drop language tag from dune code fences Plain fences for the `(libraries ...)` snippets; `lisp` highlighting was misleading for dune syntax. Co-Authored-By: Claude Opus 4.8 --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 5309a55..535af19 100644 --- a/README.md +++ b/README.md @@ -21,7 +21,7 @@ opam pin add scribe "https://github.com/sambyeol/scribe.git#v0.1.0" Then depend on the libraries from your dune file: -```lisp +``` (libraries scribe scribe.sinks) ``` @@ -29,7 +29,7 @@ Then depend on the libraries from your dune file: Use the core logger with the JSON adapter: -```lisp +``` (libraries scribe scribe.sinks) ``` From e9a004f08bb8bd6259a872b9277a4554e9959f3e Mon Sep 17 00:00:00 2001 From: Henry Lee Date: Tue, 2 Jun 2026 07:56:14 +0000 Subject: [PATCH 4/4] docs: remove duplicated dune libraries snippet The `(libraries scribe scribe.sinks)` line now lives in the Installation section; drop the duplicate from Quick Start so it leads straight into the usage example. Co-Authored-By: Claude Opus 4.8 --- README.md | 4 ---- 1 file changed, 4 deletions(-) diff --git a/README.md b/README.md index 535af19..2675ec2 100644 --- a/README.md +++ b/README.md @@ -29,10 +29,6 @@ Then depend on the libraries from your dune file: Use the core logger with the JSON adapter: -``` -(libraries scribe scribe.sinks) -``` - ```ocaml let logger = Scribe.create