Installation

Three Composer packages and a folder.

Requirements #

  • PHP 8.5 or later
  • the ds extension, 2.0 or later
  • the mbstring extension
  • Composer

Barntree needs PHP to run. It asks nothing of the language of the thing a Tree is about.

Packages #

PackageWhat it gives you
rmb32/barntreeThe library: Trees, Templates, Constructions, revisions and projections.
rmb32/barntree-cliThe barntree command. It installs the library with it.
rmb32/barntree-guiThe browser app, which barntree gui starts.
$ composer require --dev rmb32/barntree-cli rmb32/barntree-gui

Without the browser app installed, gui simply isn’t offered. To use only the library from your own code:

$ composer require rmb32/barntree

Make a barn #

$ vendor/bin/barntree init
Made a barn: …/allotment
Trees live in: …/allotment/.barn/barntree/trees

Run from a folder inside another barn, init names that barn and asks before making a separate one. With --no-interaction it refuses, unless --separate-barn says to go ahead.

Without a barn #

$ vendor/bin/barntree template:list
No barn found. Run barntree init to make one.

Commands that read or change a barn refuse outside one, write nothing and exit with 1. The browser app offers to make one in the browser.