Package: filesystem

Driver-based abstraction over file storage backends behind a single StorageInterface.

Package: filesystem

filesystem provides a lightweight, driver-based abstraction over file storage backends. It exposes a single StorageInterface with helpers for common operations — copying, moving, deleting, listing, and reading files — while delegating the underlying work to the driver you configure.

Repository: https://github.com/dracory/filesystem

Installation

go get github.com/dracory/filesystem

Features

  • Uniform StorageInterface — swap local disk for SQL or cloud storage without changing call sites.
  • Drivers include local disk, SQL-backed storage (via sqlfilestore), and cloud object storage.
  • Helpers for copy, move, delete, list, and read/write of files and directories.

Where It Is Used

Powers the media subsystem — the MEDIA_DRIVER environment variable selects the driver (local, sql, s3, gcs), and the fileadmin module builds on it for file browsing.