This package is abandoned and no longer maintained. No replacement package was suggested.

Flysystem adapter for a self-destroying temporary directory

v3.0.0 2022-06-02 10:17 UTC

This package is auto-updated.

Last update: 2024-03-28 16:11:50 UTC


build Software License Packagist Version

An adapter for the Flysystem file system abstraction library which creates a temporary directory on local filesystem and which is automatically removed again on object destruct.


composer require emgag/flysystem-tempdir


As League\Flysystem\Filesystem wrapper:

use Emgag\Flysystem\Tempdir;
$fs = new Tempdir($prefix = '', $tempdir = null, $destruct = true);
// fully qualified FS path
$fsPath = $fs->getPath();

or as Flysystem Adapter:

use Emgag\Flysystem\TempdirAdapter;
use League\Flysystem\Filesystem;

$adapter = new TempdirAdapter($prefix = '', $tempdir = null, $destruct = true);

$filesystem = new Filesystem($adapter);
// fully qualified FS path
$fsPath = $adapter->getPath();


flysystem-tempdir is licensed under the MIT License.