You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@vdrnn and @vdrnn extended a bit your amazing Sync-Script by Multisite support and auto-purging of the last n backups. Thought you might be interested in the additions:
search-replace "${FROMSITE#*//}" "${TOSITE#*//}" --all-tables-with-prefix --include-columns=domain is for wp_site & wp_blocks tables. A replacement of the domain, not the URL, is required there.
The auto-purging is a bit experimental, but works fine for us so far. We want the backups to be kept in a subfolder /backups (wp db export --file=./backups/$(date +'%Y-%m-%d_%H-%M-%S').sql --default-character-set=utf8mb4) and we only want to keep the last 5 files (find ./backups -name '*.sql' | sort -nr | tail -n +6 | xargs rm -f). I think you get the idea.
Activity