Problem/Motivation
The module currently does not provide a command-line workflow for cleaning orphaned block content entities.
Site administrators and developers should be able to execute orphan cleanup operations directly through Drush for automation, scripting, and maintenance workflows.
A Drush cleanup command would also provide a safer operational workflow when combined with dry-run support.
Steps to reproduce
- Create orphaned custom block content entities
- Attempt to remove orphaned blocks using Drush
- Observe that no dedicated orphan cleanup command exists
Proposed resolution
- Create a Drush command class for Block Content Explorer
- Add a dedicated orphan cleanup command
- Use the existing
OrphanCleaner service for cleanup operations
- Add support for configurable cleanup limits
- Add dry-run support for safe preview execution
- Display cleanup results through CLI output
Remaining tasks
- Create Drush command class
- Register Drush services
- Inject orphan cleanup service
- Implement orphan cleanup command
- Add dry-run option support
- Test command execution using Drush
- Verify cleanup logging behavior
User interface changes
None.
This issue adds command-line functionality only.
API changes
Adds new Drush command integration for orphan cleanup operations.
Data model changes
None.
Comments
Comment #4
oshi02 commentedComment #5
mohnish s. yadav