Initial Drupal 11 with DDEV setup

This commit is contained in:
gluebox
2025-10-08 11:39:17 -04:00
commit 89ef74b305
25344 changed files with 2599172 additions and 0 deletions

View File

@ -0,0 +1,66 @@
<?php
namespace Consolidation\SiteProcess\Transport;
use Consolidation\SiteProcess\SiteProcess;
use Consolidation\SiteAlias\SiteAliasInterface;
use Consolidation\SiteProcess\Util\Shell;
/**
* SkprTransport knows how to wrap a command to run on a site hosted
* on the Skpr platform.
*/
class SkprTransport implements TransportInterface
{
/** @var \Consolidation\SiteAlias\SiteAliasInterface */
protected $siteAlias;
public function __construct(SiteAliasInterface $siteAlias)
{
$this->siteAlias = $siteAlias;
}
/**
* @inheritdoc
*/
public function configure(SiteProcess $process)
{
$path = $this->siteAlias->getDefault('skpr.path', getcwd());
if ($path) {
$process->chdirToSiteRoot($path);
}
}
/**
* inheritdoc
*/
public function wrap($args)
{
$environment = $this->siteAlias->get('skpr.env');
$transport = [
'skpr',
'exec',
"$environment",
];
$transport[] = "--";
return array_merge($transport, $args);
}
/**
* @inheritdoc
*/
public function addChdir($cd_remote, $args)
{
return array_merge(
[
'cd',
$cd_remote,
Shell::op('&&'),
],
$args
);
}
}