Skip to content

Releases

1.2.2

Choose a tag to compare

@zaiev zaiev released this 10 Nov 03:15
Immutable release. Only release title and notes can be modified.

litany 1.2.2 is published as hypha-litany, its first release on open-opam, and its releases no longer go to Hypha's opam repository.

Upgrading

  • The package litany → hypha-litany. The command is still litany, and nothing it does changes.
  • Install it from open-opam: opam repo add open-opam https://github.com/open-opam/opam-repository.git, then opam install hypha-litany.

1.2.1

Choose a tag to compare

@zaiev zaiev released this 10 Nov 02:57
Immutable release. Only release title and notes can be modified.

litany 1.2.1 is not on open-opam: its archive names its version 1.2.0-4-gbfbf6f6, the commit after 1.2.0. Install 1.2.2 instead.

1.2.0

Choose a tag to compare

@zaiev zaiev released this 06 Nov 15:34

A release that makes --fix safer, makes litany refuse rather than crash, holds the newer rules to what their docs say, and prints its real version.

Upgrading

  • A fix that writes &&, Option, Result or Filename is applied by plain --fix only where that name is the standard library's; elsewhere it needs --unsafe.
  • wildcard-over-owned-variant, open-of-ordinary-module, untyped-ignore and untyped-wildcard-binding are nursery: naming one still runs it, and --select restriction no longer does.
  • litany check --root DIR enters DIR, so paths print relative to it.

New

Fixed

--fix

  • It keeps a file's permission bits, whatever the umask.
  • It parses an .mli as an interface, where a module or class declaration was refused, and prints none of the compiler's warnings.
  • A shadowed name no longer changes what a program computes, and a constructor chosen by its expected type, or a bracket in a character literal or comment, no longer breaks the build.
  • trailing-whitespace no longer fires inside a string, where its fix changed the string.

Rules

  • wildcard-over-owned-variant no longer fires on another library's variant through a module alias, or on an extensible variant.
  • open-of-ordinary-module reads constructors in patterns, fields and submodule members, and tells a name written out in full from one taken through the open.
  • untyped-ignore and untyped-wildcard-binding fire on (e : _) and (e : 'a); untyped-ignore accepts a coercion.
  • restricted-export-name reads every variable a root pattern binds.
  • suspicious-str-formatter promises no fix, as it never emitted one.

Running

  • litany --version prints the release's version, where every release printed dev.
  • --root works from any directory, and an (only ...) or (except ...) scope no longer fails the rule under an absolute root.
  • A refused pipe or fork continues without workers, and a dune that can't start is a refusal, where both were internal errors.
  • litany units --save keeps one entry for a source with two artifact copies, and --dump prints intf-source.
  • An executable or library named only by public_name no longer withholds the project rules.
  • With GITHUB_ACTIONS set, --explain-withheld keeps the text page.

1.1.1

Choose a tag to compare

@zaiev zaiev released this 03 Nov 14:08

A fix for web parts on Hypha Stack: a Melange library run through a preprocessor, and screens written in mlx, are now linted.

Fixed

  • A Melange library preprocessed by melange.ppx or ppx_solidtype is linted: dune compiles its modules from the preprocessed copies in .melange_src/, which are now named before the plain ones.
  • An implementation written in mlx's dialect is paired with its .mlx, and read from the OCaml dune turns it into.

1.1.0

Choose a tag to compare

@zaiev zaiev released this 03 Nov 12:48

Hypha's first release of its fork of invariant-hq/litany: installable from Hypha's opam repository, reading Melange and opam switches, with new restriction rules.

Upgrading

  • Install from Hypha's opam repository: opam repo add hypha https://github.com/hyphatech/opam-repository.git, then opam install litany.

New

  • wildcard-over-owned-variant: a _ arm in a match over a variant the code owns; (owned <library> ...) names the libraries besides the unit's own.
  • untyped-ignore and untyped-wildcard-binding: a value discarded by ignore or let _ without naming its type.
  • open-of-ordinary-module: a file-wide open through which a unit takes anything but binding operators; rules may now be called at every structure-level open, Rule.open_.
  • restricted-dependency forbids take (only <glob> ...) and (except <glob> ...) after their remedy, in per-path's glob grammar, re-exported as Rule.Glob.

Fixed

  • A Melange library is linted: its units were skipped as stale, since dune compiles copies of them in .melange_src/.
  • A library installed in an opam switch, Unix and Eio among them, resolves: only dune's package store was searched.
  • dune is started with no signal blocked, where a blocked mask made it print that it failed to handle one.
  • The test suite runs on released dune 3.23, on Linux, with no colour, wherever it runs.