Core LibraryunreleasedAPI Reference

Choose documentation 1

latest

Current version

latest
English

Unreleased libtmux-haskell has not been released. Its API may change during development. This site's structure and URLs may change too.

Haskell API

module libtmux-haskell latest

LibTmux.Version

Parse stable tmux releases and check the supported release range.

Source and package
Qualified name
LibTmux.Version
Package
libtmux-haskell
Source
src/LibTmux/Version.hs
LibTmux.Version

Description#

These functions consume supplied text. They neither execute tmux -V nor contact a server. Admission checks the inclusive 3.3a through 3.8 range; individual features still need capability and conformance checks.

Use parseVersion for input, requireSupported for supported-range admission and renderVersion for canonical output.

>>> :set -XOverloadedStrings
>>> fmap renderVersion (parseVersion "tmux 3.3a\n" >>= requireSupported)
Right "3.3a"

Members5#

Common operations1#

  • VersionError data type Invalid release syntax or a release outside the supported range.

Other members4#

  • parseVersion function Parse a stable release or the output of tmux -V, allowing one final LF. Development builds and trailing data are rejected rather than assigned capabilities from a guessed stable version. Diagnostics retain at most 64 chars.
  • renderVersion function Render the canonical release without the executable name or newline.
  • requireSupported function Admit every stable release from 3.3a through 3.8, including intermediate releases. Versions outside that range fail. Individual features need their own capability checks; passing this check does not qualify an entire release.
  • TmuxVersion data type A stable release, constructed by parseVersion and rendered by renderVersion. Ordering compares numeric components before the patch letter.

Guides#

Pages that discuss LibTmux.Version.

Esc

Type to search.

Reference previewOpen reference