PHP Class Platformsh\Cli\Local\Toolstack\Drupal

Inheritance: extends ToolstackBase
显示文件 Open project: commerceguys/platform-cli Class Usage Examples

Public Methods

Method Description
build ( )
detect ( $appRoot )
getKey ( )
install ( )
isDrupal ( string $directory, mixed $depth = '< 2' ) : boolean Detect if there are any Drupal applications in a folder.

Protected Methods

Method Description
buildInProfileMode ( string $profileName ) Build in 'profile' mode: the application contains a site profile.
buildInProjectMode ( string $projectMake ) Build in 'project' mode, i.e. just using a Drush make file.
checkIgnored ( string $filename, string $suggestion = null ) Check that an application file is ignored in .gitignore.
findDrushMakeFile ( boolean $required = false, boolean $core = false ) : string | false Find the preferred Drush Make file in the app root.
getDrushFlags ( ) : array Set up options to pass to the drush commands.
getDrushHelper ( ) : DrushHelper
processSettingsPhp ( ) Handle a custom settings.php file for project and profile mode.

Method Details

build() public method

public build ( )

buildInProfileMode() protected method

Build in 'profile' mode: the application contains a site profile.
protected buildInProfileMode ( string $profileName )
$profileName string

buildInProjectMode() protected method

Build in 'project' mode, i.e. just using a Drush make file.
protected buildInProjectMode ( string $projectMake )
$projectMake string

checkIgnored() protected method

Check that an application file is ignored in .gitignore.
protected checkIgnored ( string $filename, string $suggestion = null )
$filename string
$suggestion string

detect() public method

public detect ( $appRoot )

findDrushMakeFile() protected method

Find the preferred Drush Make file in the app root.
protected findDrushMakeFile ( boolean $required = false, boolean $core = false ) : string | false
$required boolean
$core boolean
return string | false The absolute filename of the make file.

getDrushFlags() protected method

Set up options to pass to the drush commands.
protected getDrushFlags ( ) : array
return array

getDrushHelper() protected method

protected getDrushHelper ( ) : DrushHelper
return Platformsh\Cli\Helper\DrushHelper

getKey() public method

public getKey ( )

install() public method

public install ( )

isDrupal() public static method

Detect if there are any Drupal applications in a folder.
public static isDrupal ( string $directory, mixed $depth = '< 2' ) : boolean
$directory string
$depth mixed
return boolean

processSettingsPhp() protected method

If the user has a custom settings.php file, and we symlink it into sites/default, then it will probably fail to pick up settings.local.php from the right place. So we need to copy the settings.php instead of symlinking it. See https://github.com/platformsh/platformsh-cli/issues/175
protected processSettingsPhp ( )