Expand description
Where the daemon puts its mounts, and what it calls each one.
Mounts go under one root directory, one subdirectory per device, so a file
manager or a script can watch a single predictable path and see devices come
and go. $XDG_RUNTIME_DIR/mtp is that root: it’s per-user, it’s a tmpfs the
session owns, and the OS clears it at logout, so a daemon that dies without
cleaning up can’t leave anything behind past the session.
Constants§
- RUNTIME_
SUBDIR - Subdirectory of
$XDG_RUNTIME_DIRthat holds the mounts.
Functions§
- device_
dir_ name - The directory name a device gets under the mount root.
- mount_
root_ from_ env - Resolve the mount root from the live environment.
- resolve_
mount_ root - Resolve the directory that holds all the mounts.