tourze/flysystem-bundle

Installs: 91

Dependents: 1

Suggesters: 0

Security: 0

Stars: 0

Watchers: 0

Forks: 0

Open Issues: 0

pkg:composer/tourze/flysystem-bundle

This package is auto-updated.

Last update: 2025-12-20 17:16:21 UTC


README

English | 中文

A Symfony bundle providing Flysystem filesystem abstraction with console commands for file management.

Installation

composer require tourze/flysystem-bundle

Commands

flysystem:list

List files and directories in remote storage.

# List root directory
php bin/console flysystem:list

# List specific path
php bin/console flysystem:list uploads/images

# List recursively
php bin/console flysystem:list uploads -r

# Long format with size and modification time
php bin/console flysystem:list uploads -l

# Combine options
php bin/console flysystem:list uploads -rl

flysystem:upload

Upload local file or directory to remote storage.

# Upload a single file
php bin/console flysystem:upload /path/to/file.txt

# Upload to specific destination
php bin/console flysystem:upload /path/to/file.txt remote/path

# Upload directory
php bin/console flysystem:upload /path/to/directory

# Overwrite existing files
php bin/console flysystem:upload /path/to/file.txt -o

# Dry run (preview without uploading)
php bin/console flysystem:upload /path/to/directory --dry-run

# Progress bar only (suppress per-file output)
php bin/console flysystem:upload /path/to/directory -p

flysystem:delete

Delete all files and optionally directories in a specified path recursively.

# Delete files (with confirmation)
php bin/console flysystem:delete uploads/temp

# Force delete without confirmation
php bin/console flysystem:delete uploads/temp -f

# Dry run (preview without deleting)
php bin/console flysystem:delete uploads/temp --dry-run

# Include directories
php bin/console flysystem:delete uploads/temp -d

Configuration

The bundle uses a default local filesystem adapter. You can customize the filesystem by implementing FilesystemFactoryInterface.

License

MIT