Skip to content
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

Drush commands for workspaces - #5933 #5934

Open
wants to merge 4 commits into
base: 13.x
Choose a base branch
from

Conversation

malcomio
Copy link
Contributor

@malcomio malcomio commented Mar 25, 2024

Aims to fix #5933

return;
}

$workspace->publish();
Copy link
Contributor Author

Choose a reason for hiding this comment

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

this fails with wse enabled, because \Drupal\wse_preview\Negotiator\CookieWorkspaceNegotiator::unsetActiveWorkspace tries to get the user session

Choose a reason for hiding this comment

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

I'll look into this asap :)

#[CLI\Command(name: 'workspaces:publish')]
#[CLI\Argument(name: 'id', description: 'The workspace to publish.')]
#[CLI\Usage(name: 'workspaces:publish stage', description: 'Publish the stage workspace')]
public function commandName($id) {

Choose a reason for hiding this comment

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

We need to ensure that the module is enabled: #[CLI\ValidateModulesEnabled(modules: ['workspaces'])]

@weitzman
Copy link
Member

weitzman commented Sep 3, 2024

This needs Drush test coverage. I think an integration test will fit well. As setup the command would create a workspace, make it active, create a node in the workspace, run the drush command, and ensure the node is now published.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Drush commands for workspaces
3 participants