-
Notifications
You must be signed in to change notification settings - Fork 269
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Local Environment: Auto-activate plugin or theme when running for the first time #238
Comments
In my fork I created an auto-mount of it's different than auto-activating a plugin, but I thought it was in a less surprising way that keeps control in the hands of the person using the tool - it's a behavior already there in WordPress and not a new surprise inside the Playground |
Makes sense. We automatically log the user in, though, so I think it's reasonable that auto-activating the plugin could be seen as a sensible default. |
there's at least one difference to consider: auto-activating carries side-effects. the activation hook never runs for it is pretty easy to run an activation hook manually via just wanted to note this here as a possible good idea with unanticipated consequences. |
Ah, good point. |
I wonder if it would make sense to add WP-CLI support first (WordPress/playground-tools#25), and then handle theme auto-activation with WP-CLI... |
@danielbachhuber you can already auto-activate plugins using the wordpress-playground/packages/playground/blueprints/src/lib/steps/activate-plugin.ts Lines 4 to 19 in eeb6b06
In general, I'd like to keep adding these utilities to Blueprints even if they overlap with what's already implemented wp-cli. This is because |
@adamziel Cool, works for me 👍 |
When running
wp-now
for the first time in a plugin or theme directory, it would be nice if the codebase was automatically activated.However, we don't want to re-activate on server start if the user already deactivated the plugin or theme.
Done is:
wp-now
for the first time auto-activates the plugin or theme.The text was updated successfully, but these errors were encountered: