PHPackages                             rayblair/filesystem - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [File &amp; Storage](/categories/file-storage)
4. /
5. rayblair/filesystem

ActiveLibrary[File &amp; Storage](/categories/file-storage)

rayblair/filesystem
===================

0.2.0(5y ago)08.9kMITPHPPHP ^7.1

Since Dec 16Pushed 5y ago1 watchersCompare

[ Source](https://github.com/rayblair06/filesystem)[ Packagist](https://packagist.org/packages/rayblair/filesystem)[ Docs](https://github.com/rayblair/filesystem)[ RSS](/packages/rayblair-filesystem/feed)WikiDiscussions master Synced 1w ago

READMEChangelogDependencies (2)Versions (3)Used By (0)

Filesystem
==========

[](#filesystem)

[![Latest Version on Packagist](https://camo.githubusercontent.com/7f94eebe345f7d8bc99ba1e0d0ea39999bf9a3cdb2e1347a7657a89110f37fb1/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f726179626c6169722f46696c6573797374656d2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/rayblair/Filesystem)[![Build Status](https://camo.githubusercontent.com/8899874ae7b733a18c514607649b1e4879ac60209b2330dce2599062f0ddcafe/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f726179626c6169722f46696c6573797374656d2f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/rayblair/Filesystem)[![Quality Score](https://camo.githubusercontent.com/263b4986dbabbb9e25f7ce6c67cd4ae22a61aa2a4eb7ac91a239b5767af966f8/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f726179626c6169722f46696c6573797374656d2e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/rayblair/Filesystem)[![Total Downloads](https://camo.githubusercontent.com/59ef94327d89229f788d938bf236ae4576ed4ce5eec760cbd6c3133cc710354d/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f726179626c6169722f46696c6573797374656d2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/rayblair/Filesystem)

A collection of handy functions to extend Laravel's filesystem.

### Detect and resolve filesystem from service container

[](#detect-and-resolve-filesystem-from-service-container)

Automatically define the filesystem disk, and keep the filesystem consistent through the application based on environment settings.

Default to s3, unless environment is sandbox, or environment is local and doesn't have s3.

### Extend the filesystem's functionality

[](#extend-the-filesystems-functionality)

Extend Laravel's Storage facade with your own functionality.

### MoveToDisk command

[](#movetodisk-command)

Easily move files from one disk to another.

Installation
------------

[](#installation)

Update `composer.json` with the following:

```
"require": {
        ...
        "rayblair/filesystem": "0.2.0"
    },
    "repositories": [
        ...
        {
            "type": "vcs",
            "url": "https://github.com/rayblair06/filesystem.git"
        },
        ...
    ],

```

Usage
-----

[](#usage)

### Resolve from Service Container

[](#resolve-from-service-container)

Makesure to resolve all Storage uses from the service container.

```
use Illuminate\Contracts\Filesystem\Filesystem;

// Normal Use
Storage::get($filename);

// Our Use
app(Filesystem::class)->get($filename);

```

### Extend the filesystem's functionality

[](#extend-the-filesystems-functionality-1)

Adding new methods to `ExtendFilesystem.php` will allow you use them while resolving from the service container

```
class ExtendFilesystem
{
    ...
    public function foo()
    {
        return 'bar';
    }
    ...
}

use Illuminate\Contracts\Filesystem\Filesystem;

// Returns the string 'bar'
app(Filesystem::class)->foo();

```

### MoveToDisk command

[](#movetodisk-command-1)

Command `php artisan move:to-disk {from_disk} {to_disk}` will allow you to easily move files from one disk to another.

**Note: This will make use of the queuing system to move files.**

```
php artisan move:to-disk local s3

```

### Testing

[](#testing)

```
composer test
```

### Changelog

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

### Security

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Ray Blair](https://github.com/rayblair)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity18

Limited adoption so far

Community4

Small or concentrated contributor base

Maturity39

Early-stage or recently created project

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

1978d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/ab35ad2244c1203e3b7f0fdbe2d765fcdcf92c4b51cddee2b82e522c841f4650?d=identicon)[rayblair06](/maintainers/rayblair06)

---

Tags

filesystemhelperslaravelphpfilesystemrayblair

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/rayblair-filesystem/health.svg)

```
[![Health](https://phpackages.com/badges/rayblair-filesystem/health.svg)](https://phpackages.com/packages/rayblair-filesystem)
```

###  Alternatives

[league/flysystem

File storage abstraction for PHP

13.6k639.1M2.2k](/packages/league-flysystem)[league/flysystem-aws-s3-v3

AWS S3 filesystem adapter for Flysystem.

1.6k263.6M790](/packages/league-flysystem-aws-s3-v3)[knplabs/gaufrette

PHP library that provides a filesystem abstraction layer

2.5k39.8M123](/packages/knplabs-gaufrette)[knplabs/knp-gaufrette-bundle

Allows to easily use the Gaufrette library in a Symfony project

72528.6M91](/packages/knplabs-knp-gaufrette-bundle)[league/flysystem-local

Local filesystem adapter for Flysystem.

226231.8M39](/packages/league-flysystem-local)[oneup/flysystem-bundle

Integrates Flysystem filesystem abstraction library to your Symfony project.

64422.9M66](/packages/oneup-flysystem-bundle)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
