SilverStripe Development Tools: Tasks

https://enlivennorthern.nzduat.co.nz

dev → tasks

Index Page Content for Search

Collate all page content from elements and save to a field for search. Use --reindex=1 to reindex all pages across all subsites.
Parameters:
reindex
Reindex all pages, not just unindexed ones [default: 0]
offset
Pagination offset
limit
Number of pages per subsite to index [default: 1000]
Run task

Diagnose dangling link references

For every content record pointing at a missing Link ID, find where (if anywhere) that row still exists in the database. Read-only.
Parameters:
csv
Write the diagnosis to this CSV path.
log
Log path. Defaults to publish.log in the project root.
no-log
Skip writing the log file. [default: 0]
Run task

Recover dangling links from version history

For every record pointing at a missing link ID, search its version history for an earlier link ID that still exists. Read-only unless --repair.
Parameters:
repair
Apply confident (orphan) candidates: re-point the field and publish. [default: 0]
include-shared
Also apply candidates that are already used by another record. Off by default. [default: 0]
csv
Write the recovery report to this CSV path.
log
Log path. Defaults to publish.log in the project root.
no-log
Skip writing the log file. [default: 0]
Run task

Match orphaned links to dangling references

Pair orphaned Link records with the content records that point at a missing link ID, using linkfield owner back-references. Read-only unless --repair.
Parameters:
repair
Re-point dangling has_one columns at their matched orphan link and publish the result. [default: 0]
csv
Write the full match report to this CSV path.
log
Log path. Defaults to publish.log in the project root.
no-log
Skip writing the log file. [default: 0]
Run task

Link publishing audit

Find (and optionally fix) linkfield Link records that are unpublished, stale, archived or orphaned. Writes a detailed publish.log.
Parameters:
publish
Publish links found in the MISSING_LIVE and STALE_LIVE categories. Without this flag the task only reports. [default: 0]
restore-archived
Also restore archived links that are still referenced by an existing record. Implies --publish for those records. [default: 0]
csv
Write the full audit to this CSV path, e.g. --csv=link-audit.csv
log
Path for the detailed log. Defaults to publish.log in the project root.
log-all
Log every link, including the ones that are already correct. Default is to log only records needing attention plus every action taken. [default: 0]
no-log
Skip writing the log file entirely. [default: 0]
limit
Only process the first N links. Useful for a quick smoke test on production.
Run task

Worklist for links that must be re-entered

List every content record pointing at a lost link, grouped by page, with CMS edit links. Read-only.
Parameters:
csv
Write the worklist to this CSV path.
Run task

Restore lost links from the previous database

Copy missing Link records back from the pre-migration database under their original IDs. Read-only unless --restore.
Parameters:
old-db
Name of the old database. Falls back to SS_OLD_DB_NAME.
old-user
Username for the old database. Falls back to SS_OLD_DB_USERNAME.
old-password
Password for the old database. Falls back to SS_OLD_DB_PASSWORD.
old-host
Host for the old database. Defaults to the current database host.
old-port
Port for the old database. Defaults to the current database port.
restore
Actually copy the rows in. Without this the task only reports what it would do. [default: 0]
csv
Write the result to this CSV path.
log
Log path. Defaults to publish.log in the project root.
no-log
Skip writing the log file. [default: 0]
Run task

Update Linkable Class Name

Update the linkable package class name in the database so it doesn't break
Run task

Linkable Migration Task

Truncate LinkField records and migrate from Linkable records
Run task

Linkfield Set Owner Task

Set owner for silverstripe/linkfield links
Parameters:
skipBrokenLinks
Skips checking if any links are broken after migration [default: 0]
Run task

PublishLinks

No description available
Run task

Update EventDetailsPage ShowInSearch Field

Sets the ShowInSearch field to false for all EventDetailsPage records. Supports a dry run option.
Parameters:
dry
do something specific [default: 0]
Run task

Test Newsletter Notification Email

Diagnoses the newsletter sign-up notification email: shows the configured recipient, checks for a duplicate submission, and can send a real test notification.
Parameters:
send
Set to 1/true/yes to actually send a test notification
email
Email to use for the duplicate check / test submission
Run task

MintDesign\GoogleReviews\UpdateTask

No description available
Run task

File to Svg

Converts all File objects to Svg Objects if an svg
Run task

Reset Admin Failed Logins

Clears failed login attempts and lockout status for the Admin user.
Run task

Set Default Column Block Count and Content Alignment

Change null to 3 - which was old default and set the content alignment
Run task

Reset Column Items Sort Order

Reset the sort order of items in a column - use if the columns are not re-ordering correctly (Run this with the columnID in the query string)
Parameters:
columnID
do something specific [default: 0]
Run task

Migrate style fields for partner group

Migrate over the styles and title fields for new items
Run task

Clean Up Form Submission Spam Checker

Clean Up Form Submission Spam Checker
Run task

MigrateContentToElement

When installing Elemental this task converts content in the $Content field to an ElementContent
Run task

Reset Globally Enabled elements

Reset individual elements 'AvailableGlobally' setting via the YAML config
Run task

Login Session Garbage Collection Task

Removes expired login sessions and "remember me" hashes from the database
Run task

Invalidate All Login Sessions Task

Removes all login sessions and "remember me" hashes (including yours) from the database
Run task

Migrate payment message types

Fills the Type column on payment messages from legacy ClassName values
Run task

Copy pages to different subsite

Handy alternative to copying pages when creating a subsite through the UI
Parameters:
from
ID of the subsite to copy from
to
ID of the subsite to copy to
virtual
Create virtual pages instead of duplicating pages [default: 0]
Run task

Clear InterventionBackend cache

Clears caches for InterventionBackend
Run task

Deletes all temporary test databases

Cleans up leftover databases from aborted test executions (starting with ss_tmpdb)
Run task

i18n Textcollector Task

Traverses through files in order to collect the "entity master tables" stored in each module.
Parameters:
locale
Sets default locale
writer
Custom writer class (must implement the SilverStripe\i18n\Messages\Writer interface)
module
One or more modules to limit collection (comma-separated)
merge
Merge new strings with existing ones already defined in language files [default: true] [default: 1]
Run task

Checking broken External links in the SiteTree

A task that records external broken links in the SiteTree
Run task