icecave/temptation

Painless temporary files and directories that clean up after themselves.

Installs: 163

Dependents: 3

Stars: 9

Watchers: 2

Open Issues: 1

Language: PHP

1.0.0 2014-09-09 09:12 UTC

README

Build Status Test Coverage SemVer

Temptation is a simple PHP library for creating temporary files and directories that clean up after themselves.

Example

use Icecave\Temptation\Temptation;

// Use the temptation object to create files and directories ...
$temptation = new Temptation;

// Create a temporary file ...
$file = $temptation->createFile();

// Use the temporary file ...
file_put_contents($file->path(), 'This is my temp file.');

// Don't do anything else!
// The temporary file is automatically deleted when the $file object goes out of scope.

Contact us