filesystem 1.0.1

@nogc implementation of std::filesystem, for D. Standard paths, envvars.


To use this package, run the following command in your project's root directory:

Manual usage
Put the following dependency into your project's dependences section:

filesystem

The filesystem package is a @nogc D library for use in context where you can't use Phobos. It is a nulib-based, DUB package that provides a ranges of services related to filesystem:

Its design is 95% the one in std::filesystem, who did a lot of semantic work, only most of the API was D-ified and will for example expose ranges instead of iterators.

Licence

MIT + BSL-1.0.

Features

  • @nogc
  • POSIX, macOS, Windows.
  • Path manipulation with the Path struct type.
    • Path.native().toUTF16().ptr can be used in Win32 functions.
    • Path.native().ptr can be used in POSIX functions that accept zero-terminated UTF-8.
  • File type.
  • File size, in bytes.
  • File last write time, in seconds.
  • File copy, rename, and removal.
  • Recursive directory creation, listing and deletion.
  • Disc usage information.
  • Get and set environment variables.
  • Getting standard paths, such as app data, XDG config (fork of standardpaths and xdgpaths and isfreedesktop).

Documentation

See the std::filesystem documentation here: https://en.cppreference.com/cpp/filesystem

Bugs and limitations

  • Windows UNC path, \\?\ and \\.\ root pathes aren't yet supported. Windows path can't exceed MAX_PATH yet.

Dependencies

  • libc (bindings in druntime)
  • POSIX (bindings in druntime)
  • Win32 (bindings in druntime)
  • DUB packages numem, nulib, nulib:io
Dependencies:
nulib, nulib:io, objective-d
Versions:
1.0.1 2026-Sep-03
1.0.0 2026-Sep-03
~main 2026-Sep-03
Show all 3 versions
Download Stats:
  • 1 downloads today

  • 1 downloads this week

  • 1 downloads this month

  • 1 downloads total

Score:
0.1
Short URL:
filesystem.dub.pm