package locswijch

  1. Overview
  2. Docs
Bidirectional bridge between dune pkg and opam switches

Install

dune-project
 Dependency

Authors

Maintainers

Sources

v0.1.1.tar.gz
md5=45d3307da2ff22ee2a1a6c6a6c2ffa75
sha512=ee3658f4346b7b06700a9be7ab3920ba7f26285c79f677340efdf3ff2096a2f93aee68087dcee2060252e2acaac4f3d7ba17a9c6526bdd709c4891f54145f383

doc/index.html

locswijch

Bidirectional bridge between dune pkg and opam switches.

locswijch is a command-line tool; it installs no library, so this page is the whole of its documentation.

Overview

dune pkg stores built packages in _build/.pkg/, invisible to the standard opam switch mechanism that tools like ocamllsp, merlin, and utop rely on. locswijch mirrors those built artifacts into a real opam switch using hard links, so editor tooling works unchanged, and the switch doubles as a backup of dune.lock/ and _build/.pkg/ that survives dune clean.

Subcommands

  • sync — mirror a project's _build/.pkg/ into an opam switch.
  • restore — rebuild _build/.pkg/ from a previously synced switch.
  • migrate — derive a dune.lock/ from an existing opam switch.
  • trip — end-to-end round-trip test (migrate, build, sync, restore, rebuild).
locswijch sync    --project DIR
locswijch restore --project DIR
locswijch migrate --switch NAME --project DIR
locswijch trip    --switch NAME --project DIR

More

See the project repository for build instructions, design notes, and the test suite.