Skip to content

Feature/add multisite support from cli#9

Merged
dsawardekar merged 13 commits intodevelopfrom
feature/add-multisite-support-from-cli
Aug 1, 2023
Merged

Feature/add multisite support from cli#9
dsawardekar merged 13 commits intodevelopfrom
feature/add-multisite-support-from-cli

Conversation

@dsawardekar
Copy link
Copy Markdown
Collaborator

Description of the Change

This PR adds support for Multisite WordPress installations via the WP CLI commands.

  • The find command now supports a --network option
  • The index command also supports a --network option
  • The delete-index command also supports a --network option

The --network option will iterate over all the sites on a Multisite install. It also accepts a comma delimited list of site_ids to limit the operation to subset of sites, eg:- --network=1,2.

image

You can also combine the --network option with the --count option to get a summary of a block's usage across the network.

image

How to test the Change

  • Pull this branch locally
  • Network activate the block-catalog plugin on a Multisite install
  • Run the index with wp block-catalog index --network
  • Search for blocks across the network

Changelog Entry

Added - Multisite Support via WP CLI with the --network option

Credits

Props @dsawardekar

Checklist:

  • I agree to follow this project's Code of Conduct.
  • I have updated the documentation accordingly.
  • I have added tests to cover my change.
  • All new and existing tests pass.

@dsawardekar dsawardekar requested a review from jeffpaul July 27, 2023 06:39
@jeffpaul jeffpaul added this to the 1.5.0 milestone Jul 31, 2023
@jeffpaul jeffpaul requested review from a team and Sidsector9 and removed request for a team and jeffpaul July 31, 2023 13:12
Copy link
Copy Markdown
Member

@Sidsector9 Sidsector9 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tests well on both single and multisite installs 👍

@dsawardekar dsawardekar merged commit d779804 into develop Aug 1, 2023
@dsawardekar dsawardekar deleted the feature/add-multisite-support-from-cli branch August 1, 2023 13:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants