From b2d2557a27b33ac1a90b149ab173e6c584ddd7bf Mon Sep 17 00:00:00 2001 From: jutty Date: Wed, 26 Jun 2024 11:22:40 -0300 Subject: [PATCH] Expand docs on configuration file structure --- docs/data.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/docs/data.md b/docs/data.md index 83af9f2..b787837 100644 --- a/docs/data.md +++ b/docs/data.md @@ -1,3 +1,28 @@ User data is initially configured to $HOME/.config/tori. At this stage, this allows concentrating all necessary data in a single place, however it is not ideal to have non-configuration file there. When making these configurable, it would be interesting to move the default backup location to $HOME/.local. + +The user data is organized in two main directories: `base` and `bkp`. + +- `base`: contains the files that will be matched against the current system's files +- `bkp`: contains the original files prior to any intervention by `tori`. This directory is further split into two directories: + - `canonical`: contains the very first version found for this file prior to any intervention by `tori`. If `tori` is running for the first time on a brand new system, this directory should contain the original files shipped by the operating system. + - `ephemeral`: contains date-stamped versions of files prior to each occasion in which `tori` had to modify, delete or move them. This directory is not essential to the functioning of `tori`. It is provided as a safety net for the user and may be deleted at any time. It will be automatically recreated. + +Both of these directories mimic the file structure found from the root of the file system. For example, this is how one such structure could look like: + +``` +/home/user/.config/tori +├── base +│   └── home +│   └── user + ├── .profile +│   └── .shrc +└── bkp + └── canonical + └── home + └── user + ├── .profile + └── .shrc +``` +