Skip to content

Instantly share code, notes, and snippets.


Danny Englander danny-englander

View GitHub Profile
danny-englander /
Created May 29, 2021 — forked from miloskroulik/
How to setup xdebug + Lando + PHPstorm when using Drupal 8 recipe

I assume you're using Drupal 8 recipe and Linux as a host OS. Also, xdebug 3.x is assumed, which is standard for Lando-provided PHP image.

Set up Lando

Example .lando.yml file can look like this:

name: xdebug-test
recipe: drupal8
  webroot: web
View TwoColumnLayout.php
namespace Drupal\custom_layout\Plugin\Layout;
use Drupal\Core\Form\FormStateInterface;
use Drupal\Core\Layout\LayoutDefault;
use Drupal\Core\Plugin\PluginFormInterface;
* Configurable two column layout plugin class.
danny-englander / cloudSettings
Last active Oct 1, 2020
Custom Docksal bash script (command) to install RVM, NVM, Yarn, Gulp, and jekyll
View cloudSettings
View rvm command file
#!/usr/bin/env bash
# Place this in your project at /.docksal/commands and call this file rvm, the name should match the command.
# Run this script as fin rvm.
# Install RVM and dependancies, activate and source it, choose the version.
# These two lines are needed to have a valid RVM install
fin exec bash -c "curl -#LO"
danny-englander / uikit-icons.yml
Last active Mar 4, 2017
UIKit 3 icon listing in yaml format
View uikit-icons.yml
- name: home
category: app
- name: sign-out
category: app
- name: sign-in
category: app
- name: user
category: app
- name: users
category: app
danny-englander / field.html.twig
Created Dec 21, 2016 — forked from lewisnyman/field.html.twig
minimal field.html.twig — Drupal 8
View field.html.twig
{% for item in items %}
{{ item.content }}
{% endfor %}
View gulpfile.js
// Include gulp
var gulp = require('gulp');
// Include plugins
var jshint = require('gulp-jshint'),
plumber = require('gulp-plumber'),
sass = require('gulp-sass'),
spritesmith = require('gulp.spritesmith'),
uglify = require('gulp-uglify'),
concat = require('gulp-concat'),
danny-englander /
Last active Sep 1, 2016
An automated drush backup script with folder pruning using ZSH Globbing
#! /bin/zsh
## An automated Drupal backup script using Drush and ZSH globbing.
## Ideally place this script in usr/local/bin
## Set this to run via a cronjob.
## Easy crontab setup:
## Inspiration from: by
View gulpfile.gulp.spritesmith.js
var gulp = require('gulp'),
sass = require('gulp-ruby-sass'),
spritesmith = require('gulp.spritesmith'),
compass = require('gulp-compass'),
path = require('path'),
minifyCss = require('gulp-minify-css'),
browserSync = require('browser-sync'),
tinypng = require('gulp-tinypng'),
autoprefixer = require('gulp-autoprefixer'),
plumber = require('gulp-plumber');
View magnific-popup-deep-linking.js
<script type="text/javascript">
function loadGalleryDeepLink()
var prefix = "#gallery-";
var h = location.hash;
if (document.g_magnific_hash_loaded === undefined && h.indexOf(prefix) === 0)