Skip to content

Instantly share code, notes, and snippets.

class DrupalFinderInterface() {
public function getDrupalRoot();
public function getComposerRoot();
public function getVendorDir();
}
<?php
declare(strict_types=1);
namespace DrupalFinderPlugin;
/**
* This class is generated by webflo/drupal-finder-plugin, specifically by
* @see \DrupalFinderPlugin\Installer
*
{
"name": "drupal-composer/drupal-security-advisories",
"description": "Prevents installation of composer packages with known security vulnerabilities",
"type": "metapackage",
"license": "GPL-2.0-or-later",
"conflict": {
"drupal/acquia_contenthub": "<1.0,<1.4",
"drupal/alinks": "<1.1",
"drupal/auto_login_url": "<1.2",
"drupal/bootstrap": "<3.5",
<?php
/**
* @file
* Local development override configuration feature.
*
* To activate this feature, copy and rename it such that its path plus
* filename is 'sites/default/settings.local.php'. Then, go to the bottom of
* 'sites/default/settings.php' and uncomment the commented lines that mention
* 'settings.local.php'.
@webflo
webflo / drupal-finder.php
Created October 26, 2017 15:03
drupal-finder.php
<?php
// Usage: php drupal-finder.php /var/www/some/example/path
include __DIR__ . '/vendor/autoload.php';
$path = array_pop($argv);
$finder = new \DrupalFinder\DrupalFinder();
print "Input: " . $path . PHP_EOL;
SCHEMA:
alt
title
original {
url
}
QUERY:
#!/bin/bash
# http://github.com/w00fz/xdebug-osx
command="$1"
php_version_dot=$(php -r "\$v=explode('.', phpversion() ); echo implode('.', array_splice(\$v, 0, -1));")
php_version="${php_version_dot//./}"
xdebug_conf_path="$(brew --prefix)/etc/php/$php_version_dot/conf.d"
xdebug_conf_file="ext-xdebug.ini"
@webflo
webflo / phpstorm
Last active January 29, 2017 18:36
#!/bin/bash
filepath=$@
if [ ${filepath: -1} = ":" ]; then
filepath="${filepath%?}"
fi
$HOME/bin/appswitch -a PhpStorm
$HOME/bin/pstorm $filepath
/**
* Implements hook_install().
*
* Performs actions to set up the site for this profile.
*
* @see system_install()
*/
function blubb_install() {
global $config_directories;