scryba / laravel-google-drive-filesystem
Google Drive filesystem adapter for Laravel (10, 11, 12)
Fund package maintenance!
michael.laweitech.com/buy-me-a-coffee
Requires
- php: ^8.1
- google/apiclient: ^2.15
- illuminate/filesystem: ^10.0|^11.0|^12.0
- illuminate/support: ^10.0|^11.0|^12.0
- league/flysystem: ^3.0
Requires (Dev)
- orchestra/testbench: ^8.0|^9.0
- phpunit/phpunit: ^10.0
README
Google Drive filesystem adapter for Laravel 10, 11, and 12.
- Author: Michael K. Laweh (contact@michael.laweitech.com)
- Homepage: https://michael.laweitech.com/
- Repository: https://github.com/scryba/laravel-google-drive-filesystem
- Funding: Buy me a coffee
Quick Installation
Install via Composer:
composer require scryba/laravel-google-drive-filesystem
For advanced installation and VCS/development setup, see docs/INSTALLATION.md.
Quick Configuration
Publish the config file and set up your .env
:
php artisan vendor:publish --tag=google-drive-config
Add your Google Drive credentials to your .env
file. For a detailed step-by-step guide, see docs/GETTING-TOKENS.md.
Usage
After configuring, you can use the Google Drive disk in your Laravel application like this:
use Illuminate\Support\Facades\Storage; // Store a file Storage::disk('google')->put('example.txt', 'Hello, Google Drive!'); // Retrieve a file $content = Storage::disk('google')->get('example.txt'); // List files in a directory $files = Storage::disk('google')->files('/'); // Delete a file Storage::disk('google')->delete('example.txt');
For advanced usage, see docs/USAGE.md.
Laravel Compatibility
- Laravel 10.x, 11.x, 12.x
- PHP 8.1+
License
MIT
Support
For issues, bug reports, or feature requests, please visit the GitHub Issues page.