https://github.com/edofre/laravel-softdelete-cleanup
Cleanup your database from softdeleted models
https://github.com/edofre/laravel-softdelete-cleanup
artisan composer console laravel laravel-softdelete-cleanup
Last synced: 7 months ago
JSON representation
Cleanup your database from softdeleted models
- Host: GitHub
- URL: https://github.com/edofre/laravel-softdelete-cleanup
- Owner: Edofre
- License: mit
- Created: 2017-02-02T08:00:36.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2020-09-04T07:43:55.000Z (almost 6 years ago)
- Last Synced: 2025-03-21T09:16:09.379Z (over 1 year ago)
- Topics: artisan, composer, console, laravel, laravel-softdelete-cleanup
- Language: PHP
- Size: 43.9 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGE.MD
- License: LICENSE.md
Awesome Lists containing this project
README
# Laravel Softdelete Cleanup
[](https://packagist.org/packages/edofre/laravel-softdelete-cleanup)
[](https://packagist.org/packages/edofre/laravel-softdelete-cleanup)
[](https://packagist.org/packages/edofre/laravel-softdelete-cleanup)
[](https://packagist.org/packages/edofre/laravel-softdelete-cleanup)
[](https://packagist.org/packages/edofre/laravel-softdelete-cleanup)
[](https://travis-ci.org/Edofre/laravel-softdelete-cleanup)
[](https://codeclimate.com/github/Edofre/laravel-softdelete-cleanup)
[](https://travis-ci.org/Edofre/laravel-softdelete-cleanup)
## Installation
The preferred way to install this extension is through [composer](http://getcomposer.org/download/).
To install, either run
```
$ php composer.phar require edofre/laravel-softdelete-cleanup
```
or add
```
"edofre/laravel-softdelete-cleanup": "V1.3.0"
```
to the ```require``` section of your `composer.json` file.
## Executing
The following command will then remove all the trashed items from the User, note that the User model is not in the default namespace.
```
php artisan db:softdelete-cleanup App\\Models\\User
```
## Tests
Run the tests by executing the following command:
```
composer test
```
## Feature requests
* Set the number of days from which the items should be deleted
* ?