liveBook · Manning

Directory structure

Also called folder structure, file structure

A directory structure is the hierarchical organization of directories and files within a filesystem or project.

How 8 Manning books explain it

The Quick Python Book, Fourth Edition

A directory is a filesystem container that organizes files and other directories under a named location.

How it is used
Organizes files for traversal, archiving, and Python package layout.
How deep it goes
Explains tree and pathname conventions, directory operations, traversal options, and archive layouts; defers advanced filesystem functions to library documentation.
Examples
Demonstrates pruning .config during a walk and grouping daily files into date-named archive subdirectories.
What you can do after
Apply it via Python’s os and pathlib to create, traverse, and organize directories.

Read how The Quick Python Book, Fourth Edition explains directory structure →

A Pythonic Adventure: From Python basics to a working web app

A directory, also called a folder, is a filesystem container used to organize files and other directories.

How it is used
Organizes application files by project and type, keeping separate projects from becoming mixed together.
How deep it goes
Defines folders and directories, then applies them to a practical application structure without exploring filesystem internals.
Examples
Uses Projects/coffeeshop with templates, static, images, fonts, app.py, and other application files.
What you can do after
Operate/configure projects by separating application files into organized project and asset directories.

Read how A Pythonic Adventure: From Python basics to a working web app explains directory structure →

Learn AI-Assisted Python Programming, Second Edition

A directory is a filesystem container that organizes files and other directories by name.

How it is used
Organizes a practical automation task that combines files from multiple source directories into one target directory.
How deep it goes
Explains directory listing, comparison, copying, duplicate handling, and testing, but stops short of filesystem internals.
Examples
Demonstrates merging pictures1 and pictures2 into pictures_combined while removing duplicate PNG files.
What you can do after
Build it from scratch using os, filecmp, and shutil to merge directories without duplicating identical files.

Read how Learn AI-Assisted Python Programming, Second Edition explains directory structure →

Coding with AI

A directory is a file-system container that organizes files and other directories at a path.

How it is used
Organizes a Flask application as it grows beyond a single file.
How deep it goes
Demonstrates a suggested Flask layout, integrates stubs, and revises the proposal without treating it as authoritative.
Examples
Uses a Flask quiz application with question selection, templates, tests, and placeholder methods.
What you can do after
Build it from scratch by arranging Flask application responsibilities into files and adding implementations incrementally.

Read how Coding with AI explains directory structure →

Python How-To

A project folder structure is an organized arrangement of directories and files that groups related source artifacts within a software project.

How it is used
Organizes project source files and experimental data so related artifacts remain predictable, readable, and maintainable.
How deep it goes
Explains creation, nesting, movement, discovery, and path metadata with pathlib, stopping short of broader project conventions.
Examples
Uses data and subjects/subject_ID folders containing .config, .dat, and .txt files from a scientific experiment.
What you can do after
Build it from scratch with pathlib, then organize, move, and locate related files programmatically.

Read how Python How-To explains directory structure →

Rust Servers, Services, and Apps

A project structure is the organization of a software project's files, directories, modules, and related artifacts.

How it is used
Reshapes a growing web service so its code is easier to develop and maintain.
How deep it goes
Shows a concrete file-and-folder reorganization and its tradeoff, without detailing every resulting file.
Examples
Uses a course-and-tutor service layout with separate database-access, handler, and model folders.
What you can do after
Apply Rust modules to reorganize a growing service into navigable, responsibility-focused folders.

Read how Rust Servers, Services, and Apps explains directory structure →

The Well-Grounded Python Developer: How the pros use Python and Flask

A directory is a filesystem container that organizes files and other directories under a name.

How it is used
Organizes files and subdirectories to prevent naming collisions and keep growing projects understandable.
How deep it goes
Explains the naming rationale, demonstrates a directory-design experiment, and visualizes hierarchy without implementation commands.
Examples
Uses identically named expenses.xlsx files, dated expense directories, and simple or granular hierarchy diagrams.
What you can do after
Build directory hierarchies that separate repeated filenames and scale from coarse to granular organization.

Read how The Well-Grounded Python Developer: How the pros use Python and Flask explains directory structure →

Python Workout, Second Edition

A directory is a filesystem container that organizes files and other directories under a name.

How it is used
Organizes multiple Python modules so they can be imported together as a package.
How deep it goes
Explains package layout, import forms, sys.path, and __init__.py, while stopping short of filesystem operations.
Examples
Uses mypackage with first.py, second.py, third.py, and __init__.py to demonstrate alternative import paths.
What you can do after
Apply it via Python imports to group modules and access them through short or fully qualified names.

Read how Python Workout, Second Edition explains directory structure →

Also covered in

What to know first

Related concepts

Questions about directory structure

What is directory structure?

A directory structure is the hierarchical organization of directories and files within a filesystem or project.

Which Manning books explain directory structure?

The Quick Python Book, Fourth Edition, A Pythonic Adventure: From Python basics to a working web app, Learn AI-Assisted Python Programming, Second Edition, Coding with AI, Python How-To, Rust Servers, Services, and Apps, The Well-Grounded Python Developer: How the pros use Python and Flask and Python Workout, Second Edition.

What should I know before learning directory structure?

Manning books that teach directory structure usually introduce Python, filename, file path and backslash first.

What kinds of directory structure are there?

Kinds of directory structure include package.

What is directory structure a kind of?

Directory structure is a kind of tree. A tree is a connected, acyclic structure of nodes organized through parent-child relationships, typically around a single root.

What is directory structure also called?

Directory structure is also called folder structure or file structure.

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.