sarahandClaude Opus 5.5 918e1d68cf Flow edit mode: edit arrow rules, delete directories
Each rule on an arrow can be edited (pattern, NewFileName, case-sensitive,
overwrite); a rule shared with other inputs is split so only this arrow
changes. Connecting an input with a pattern an output already has no longer
renames it for the other inputs. Boxes get a delete button that removes the
directory from SaraSortd (GlobalConf, other outputs' rules, its config and
history files) but never the folder itself.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-07 22:50:11 +02:00

SaraSort

A GUI for configuring SaraSortd, built with Flet. SaraSort doesn't sort anything itself: SaraSortd stays the backend, and SaraSort reads and edits its configs and controls its systemd user service.

Needs SaraSortd 7.1 or newer for arrows with their own patterns (per-entry ValidInputDirs).

Pages

  • Flow: every input (red), output (blue) and both (purple) directory as a box, with arrows labelled with the file patterns that travel along them. Click a label to see all of its patterns. Boxes start in columns and can be dragged (positions are kept in Layout.toml). In Edit mode: click a directory, then the one it should sort into, and type the patterns. Each pattern becomes its own [[Files]] entry in the output's config, with its own ValidInputDirs, and the other settings come from OutputDirConf.toml (the template). Click a label to edit its rules (pattern, NewFileName, case-sensitive, overwrite), add or remove patterns, remove the arrow, or save it as a template. A rule other inputs use too is split when you change it, so only this arrow changes. The bin on a box deletes the directory from SaraSortd: it leaves GlobalConf.toml and other outputs' rules, and its config and history files are deleted. The folder and its files stay.
  • Service: running/stopped, start/stop/restart, start on login, SaraSortd's version (and the SaraSuite install it came from), and its logs: its own log files or the systemd journal.
  • Configs: GlobalConf.toml, the two templates and every directory's own config, as a form (with help text, a live NewFileName preview and variable buttons) or as raw TOML. Saving only writes the values you changed, so SaraSortd's own NextNum/NextChar/LastFile updates aren't overwritten.
  • Templates: ready-made connections (Pictures, Videos, Music, Documents, Archives, Git repositories, Logs, 3D printing, Installers, Backup copy) that only ask for an input and an output. Your own templates are TOML files in ~/.config/SaraSuite/SaraSort/Templates/.
  • Tools: warnings about the setup (Unset values, version mismatches, outputs nothing reaches, inputs without outputs, entries shadowed by a catch-all), a filename tester that shows where a file would go and why, and the files in FailedDir with a retry button.

The gear button opens Settings, laid out like SaraFem's and SaraSuite's: the shared SaraSuite appearance and export/import (same file format as SaraFem's, [SaraSuite] plus [SaraSort]), SaraSort's own settings, and where SaraSortd lives. The SaraSortd tab also exports and imports all of SaraSortd's configs as one file: GlobalConf.toml, both templates and every directory's own config, comments included. Importing backs the current configs up to ~/.config/SaraSuite/SaraSort/Backups/ first. If directories it uses don't exist, you can cancel, give any of them a new path (the configs and arrows follow), or have them made. Run as an AppImage, the header also has an "Add to app menu" button, like SaraSuite's.

After a change to GlobalConf.toml (new inputs or outputs) SaraSort restarts SaraSortd, since SaraSortd only reads that file when it starts. That can be turned off in Settings.

Where things live

Path What
~/.config/SaraSuite/Config.toml shared SaraSuite settings (theme, font, title bar)
~/.config/SaraSuite/Themes/ the themes
~/.config/SaraSuite/SaraSort/Config.toml SaraSort's own settings
~/.config/SaraSuite/SaraSort/Layout.toml where flowchart boxes were dragged to
~/.config/SaraSuite/SaraSort/Templates/ your own templates
~/.config/SaraSuite/SaraSort/Backups/ SaraSortd's configs from before each import
~/.config/SaraSuite/SaraSortd/ SaraSortd's configs, as SaraSuite installs them (changeable in Settings)

Running and building

  • From source: python3 -m venv .venv && .venv/bin/pip install -r requirements.txt, then Packaging/Launch.sh.
  • AppImage: Packaging/BuildAppImage.sh builds dist/SaraSort-x86_64.AppImage (PyInstaller one-file build + appimagetool, like SaraSuite's and SaraFem's).
  • SaraSuite: Packaging/SaraSuite/ is a ready manifest (Manifest.toml + Templates/) to copy into SaraSuite's Programs/SaraSort/.

Files

File What
Main.py window, navigation
Core.py paths, palette/theme, settings, export/import
Sortd.py SaraSortd's configs: the graph, edits, the filename simulator, warnings
Service.py systemctl and journalctl
Templates.py built-in and your own templates
Settings.py the Settings dialog
SortdTransfer.py exporting/importing all of SaraSortd's configs
Widgets.py the shared App context and small controls
*Page.py one per page
S
Description
No description provided
Readme
339 KiB
0 Stars 1 Watchers 0 Forks
Languages
Python 98.7%
Shell 1.3%