Skip to content

Instantly share code, notes, and snippets.

View urbantrout's full-sized avatar

Harald Atteneder urbantrout

View GitHub Profile

Thanks to machine-drivers/docker-machine-driver-xhyve#123 (comment)

  1. Go to ~/.docker/machine/machines/machine_name
  2. sudo hdiutil resize -size new_size root-volume.sparsebundle (i.e. new size can be 30g)
  3. Edit config.json and provide new size in Driver.DiskSize property
  4. SSH to the machine
  5. sudo fdisk /dev/sda then:
    • d
    • 2
  • n
@urbantrout
urbantrout / functions.php
Created November 23, 2017 14:17
WordPress - Disable Emojis
function disable_wp_emojicons() {
// all actions related to emojis
remove_action( 'admin_print_styles', 'print_emoji_styles' );
remove_action( 'wp_head', 'print_emoji_detection_script', 7 );
remove_action( 'admin_print_scripts', 'print_emoji_detection_script' );
remove_action( 'wp_print_styles', 'print_emoji_styles' );
remove_filter( 'wp_mail', 'wp_staticize_emoji_for_email' );
remove_filter( 'the_content_feed', 'wp_staticize_emoji' );
remove_filter( 'comment_text_rss', 'wp_staticize_emoji' );
@urbantrout
urbantrout / LanguageMenu.fusion
Last active November 10, 2017 23:00 — forked from htuscher/LanguageMenu.ts2
Neos Fusion condition LanguageMenu if dimension exists
languageMenu = DimensionsMenu {
templatePath = 'resource://UrbanTrout.Site/Private/Templates/FusionObjects/LanguageMenu.html'
dimension = 'language'
# Only show languageMenu if 'en' dimension exists.
@if.condition = ${Type.className(q(node).context({'dimensions': {'language': ['en']}, 'targetDimensions': {'language': 'en'}}).get(0)) == 'Neos\ContentRepository\Domain\Model\Node'}
}