鲸须 / storage-flysystem
此包已被废弃,不再维护。未建议替代包。
提供使用FlySystem的FlyStorage类,用于Baleen迁移。
0.2.0
2015-11-11 19:25 UTC
Requires
- baleen/migrations: ^0.9
- league/flysystem: ^1.0
Requires (Dev)
- escapestudios/symfony2-coding-standard: ~2.0
- mockery/mockery: ^0.9.4
- phploc/phploc: ^2.1
- phpmd/phpmd: ^2.3
- phpunit/phpunit: *
- sebastian/phpcpd: ^2.0
- squizlabs/php_codesniffer: ^2.3
This package is not auto-updated.
Last update: 2022-05-02 15:20:15 UTC
README
此包是Baleen生态系统的一部分。它使用League的Flysystem将迁移状态存储到文件中。
状态
注意!:此项目仍处于早期发布阶段。请勿在生产环境中使用。有关更多信息,请参阅LICENSE。
安装(Composer)
使用Composer安装很简单
composer require baleen/storage-flysystem
使用方法
以下示例说明了如何使用FlyStorage与Flysystem的Local适配器一起使用。
use League\Flysystem\Filesystem; use League\Flysystem\Adapter\Local; $adapter = new Local(__DIR__.'/path/to/root'); $filesystem = new Filesystem($adapter); $storage = new FlyStorage($filesystem); // default filename is ".baleen_versions" // and then, for example: $migratedVersions = $storage->fetchAll(); // another example (save a new migrated version): $v = new \Baleen\Migrations\Version('newVersion', true); $storage->save($v);
许可证
MIT - 更多详细信息请参阅根目录下的LICENSE。