File management/Directory structures
The aim of this subpage is collecting possible directory structures for file management and archival. Feel free to add your ideas.
Archive drive[edit | edit source]
By category[edit | edit source]
In this example, vacation photos and videos are stored in directories named by month, location, and device type. The device type could be useful to note as the user likely remembers from which device they captured a particular photo or video they might be looking for.
In this example, the directory name starts with the date. When typing on the keyboard while viewing a directory listing in a file manager, it usually jumps to the item whose name starts with those characters to speed up navigation. If you wish to navigate into sub-directories by date, put the date at the beginning of the file name. If you wish to navigate by location, put that at the beginning.
Numerical months are recommended over month names due to facilitated sorting and consistent character length.
If necessary, arbitrary time spans can be noted as
Camera-20210523to20210706, or for alphanumerical sorting
If possible, directories may be named directly on the portable device. For example, after a trip, a date and location can be added to a smartphone's camera folder, like
Camera-2023_11_20-Munich. A benefit of regularly renaming populated directories is that the number of files in a directory is prevented from becoming too large, which speeds up loading times, especially on the popular but slow Media Transfer Protocol (MTP), which is commonly used for connecting smartphones to desktop/laptop computers. The camera software will automatically create a new camera folder next time it is used.
Unsorted files can be stored inside an "unsorted" folder for the time being. Files unsorted within a category can be put into a folder with an "-unsorted" suffix, such as "Screenshots-unsorted".
For large amounts of data and data used at different locations, a storage device can be dedicated to a category. For example, one storage device can be dedicated to photographs and video recordings, one for files generated during normal computer use (screenshots, web downloads), and one for work-related data such as project files, presentations, and database backups.
Chronological first[edit | edit source]
A scheme that is said to be employed by social media platforms to facilitate backups is putting time stamps at the top level. For example, that would mean putting all data created in November 2023 into a directory named
2023-11, with categorizing folders inside.
Make sure to use numerical months, not literal month names for correct sorting that are unaffected by changes to the folders' "last modified" time stamp.
To facilitate overview, sorting, and to prevent confusion, it is recommended to use a date format which starts with the largest unit (year) and then descends (ISO 8601).
If there are not many folders, the category can be added to the folder name, like the example below.
A more compact variant of the above naming scheme is putting both date and category in one directory name. This allows folder names with and without speficied month to be mixed without falsifying the sorting order:
Parent directory name first[edit | edit source]
In this naming system, other information such as dates and device names and location names are added after the name of the parent directory that contains the files. The name of files' parent directory is more memorable due to consistency across devices, such as
DCIM for cameras and consistently named subfolders such as
Camera on smartphones.
Camera vendors also use names that are consistent across their products, as shown with Panasonic in the below example. Some camcorders store recorded footage in a directory named
Downloads is commonly used for web downloads, and
Screenshots for screen captures.
With the parent directory name first, folders can be found quickly in an alphabetical sorting and through entry selection by typing into the file manager window.
If the preset name is not specific enough, such as
Pictures for screen shots, it can be named
Pictures-Screenshots, or the parent directory name can be discarded by naming it
Screenshots, since it is equally as memorable as
If one wishes to view a slide show of all photos from one location that are split across directories, and ones image viewer lacks the ability of slideshowing across multiple directories, the
111_PANA directory in the above example can optionally be merged into the
110_PANA directory. Optionally, a sign of the merge can be added to the name, such as
110_PANA+111_PANA. However, naming it
110+111_PANA is not recommended since it would interfere with the alphanumerical sorting by putting the directory above all directories starting with
Separation of fields[edit | edit source]
A double click or long touch typically selects text delimited by any character that is not alphanumerical or an underscore.
Therefore, separating fields in file names by dashes and using underscores instead of spaces facilitates selection. For example, a name like
DCIM-Costa_Bravia-2018_07_24-2018_07_20 which contains a date range allows selecting an entire date field or the name "Costa_Bravia" with a double-click or one long touch, without tedious fine selection.
Special cases[edit | edit source]
Note that some devices or programs that create new files may store them in multiple directories. For example, saved web pages' assets may be stored in a
_files subfolder, and AVCHD video cameras store an index with metadata in a separated file path (
PRIVATE/AVCHD/BDMV/CLIPINF) than the video streams (
_files subdirectory should be kept together with the accompanying HTML document to be able to display styling, images, and multimedia. The files inside
CLIPINF may be left on the memory card or backed up separately. Due to their small size, it is useful to pack them into a single-file archive.
For a reminder to complete tasks, copies of files may be created in more visible locations outside of their typical location, such as the user home directory or a flash drive's root directory, and a description of the task to be completed in the file name, like "
[upload to Commons] Logo name.svg". These duplicates can be deleted once the task is finished.
Operating system[edit | edit source]
Folders in a user's home directory are typically already created by operating systems into generic categories like "Documents", "Pictures", "Videos", "Music", "Downloads".
Users can create categories under those, such as:
- sandbox (arbitrary drafts and snippets that fit nowhere else)
- email (email drafts to be sent)
- script (programming code)
- cfg (backup of software configuration, such as custom CSS code for a web browser extension)
- sessions (exported browsing sessions moved from Download folder, if possibly necessary later)
- cmddump (command line terminal output)
- file lists
- unzip (extractions from archive files)
- ProjectName (gathering files for an impending project)
- Web (While "Downloads" is the default download location for web browsers, they can optionally be configured to store downloads into a custom folder.)
- Saved pages (can optionally be separated from other web downloads. The file saving dialogue usually memorizes the last directory saved to and opens it against next time.)
- Downloads_2 (see below for explanation)
- Screenshots (possibly already used by some operating systems)
- Video frames (still frames extracted from video footage can optionally be located separately)
- Screenshots-VM (separate folder from screenshots taken from virtual machines)
- Screencast (screen video recordings)
- sh (short directory name for quick access to shell scripts)
- unsorted (for unsorted files; can optionally be split into incoming and outgoing files)
The common download directory,
%userprofile%\Downloads on Windows and
~/download or similar on Linux-based operating systems, is subject to become populated quickly, and could therefore slow down navigation. As such, categorized downloads may be located into a directory named "Downloads_2" or similar, located in the user profile directory (not inside the main download folder, otherwise it would defeat its benefit).
Portable storage media[edit | edit source]
Portable storage media such as USB flash drives and memory cards can have a similar directory structure as those above, but there can be a dedicated folder for transferring files between devices. If the device is solely used for file transfer, the root directory can be used.
Files whose transfer has finished may be moved to a dedicated "trash" folder (manually if not done by the file manager) instead of deleted immediately, so they can be deleted when space is exhausted, but can be accessed again in case they are needed, which saves effort in comparison to having to get it from a stationary source device again.
If you have difficulty finding files, especially on portable data storage, consider creating a text file that acts as a file index in the root directory of the device or for specific sub folders. The benefit over bookmarking files within the file manager software is that it can be accessed through a text editor from any computer.
Spanning across multiple devices[edit | edit source]
Should a group of files not fit on a single storage device, the files can be spanned across multiple devices in folders with part number suffixes appended to their names:
The total part number, "of05" in this example, will help ensuring the completeness of the data in future, in case the user forgets how many parts there were.
Notes[edit | edit source]
- Whether singular or plural does not matter much, though users typically have multiple sources for photos and videos. However, the singular form could be understood as a mass noun, i.e. "Camera archive".