Skip to main content

trugs-folder

TRUGS cartography. One binary, trug-a-folder — keep a directory tree and its TRUG graph in sync, validate it against the folder governance rules, and render a human-readable ARCHITECTURE.md from it. Implements TRUGS 2.0 (core_v2.0.0).

The idea: the folder is a graph. folder.trug.json holds one node per file, typed by the governance vocabulary (code is COMPONENT, prose is DOCUMENT), and the tool keeps that graph honest as the directory changes.

Install

pip install trugs-folder

Quickstart

trug-a-folder init myproject --scan -d "My first mapped folder"
trug-a-folder check myproject
trug-a-folder render architecture myproject
trug-a-folder sync myproject        # reconcile after files change

New to TRUGS? The five-minute on-ramp: GETTING_STARTED.md

Command surface

Fourteen verbs on the trug-a-folder binary:

verb what it does
init Initialize folder.trug.json in a directory
check Validate against the governance rules
sync Reconcile the graph with the filesystem
render Render ARCHITECTURE.md from the graph
info Show summary information about a TRUG file
ls List directory contents with TRUG metadata
where Search all folder graphs for a concept, node, or file
find Query nodes by type / name / dimension
add Add files to the graph
mv Move/rename a node
link Create or remove typed edges between nodes
dim Manage dimensions
export Export folder.trug.json from the database
import Import folder.trug.json into the database

Every verb documents examples and exit codes: trug-a-folder <verb> --help.

The language CLI — validating arbitrary TRUG graphs and compiling TRL — is the sibling package trugs-tools (binary: trug), which this package builds on.

Lineage

This package descends from the cartography half of trugs-tools 1.0.0; the 2.0 release split it onto its own wheel. History is in CHANGELOG.md.

License

Apache-2.0. See LICENSE and NOTICE.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

trugs_folder-2.1.0.tar.gz (100.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

trugs_folder-2.1.0-py3-none-any.whl (75.9 kB view details)

Uploaded Python 3

File details

Details for the file trugs_folder-2.1.0.tar.gz.

File metadata

  • Download URL: trugs_folder-2.1.0.tar.gz
  • Upload date:
  • Size: 100.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.4

File hashes

Hashes for trugs_folder-2.1.0.tar.gz
Algorithm Hash digest
SHA256 8ae5c0ee36af47431fa35c24136443cb481f6d00a6215a3cdcb691f4d8ea3c29
MD5 2cb5e21476a7ab17643371f3496ef4c1
BLAKE2b-256 18833c4aeb93f709456a53e2e6abc5ddc6a25fb5ee3953cb9aae2670b47a8041

See more details on using hashes here.

File details

Details for the file trugs_folder-2.1.0-py3-none-any.whl.

File metadata

  • Download URL: trugs_folder-2.1.0-py3-none-any.whl
  • Upload date:
  • Size: 75.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.4

File hashes

Hashes for trugs_folder-2.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 fa78628debc903969ac147fcf1563e8db22b422ec57a40ba5e435b358471871a
MD5 d0199163634c96d84dd81eb9e3b023b6
BLAKE2b-256 9ff7aafc46df2ba6cfeaa19baff15eb4be49c572e5f0dd258f529fe180dad591

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page