Skip to content

Instantly share code, notes, and snippets.

@simesy
simesy / gist:7458877
Last active December 28, 2015 06:39
Put this in ~/Library/Application Support/Flowdock/userstyle.css -- Would like to make the small names use less space, but not sure how to manage the widths. -- I would like some nicer indication of which flows are private chats. -- etc etc
@media screen {
nav#tab-bar, nav.desktop {
height: auto !important;
}
ul#tab-list {
white-space: normal !important;
}
li.tab {
display: inline-block;
max-width: 150px !important;
<?php
/**
* Implements hook_module_implements_alter();
*/
function mytheme_module_implements_alter(&$implementations, $hook) {
switch($hook) {
case 'init':
case 'panels_post_render':
case 'panels_post_render':
@simesy
simesy / 0_reuse_code.js
Created April 23, 2014 04:23
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@simesy
simesy / key-replace.js
Last active August 29, 2015 14:24
Turkish key replacement for duolingo. Install this script in the Tampermonkey extension in Chrome.
// ==UserScript==
// @name Turkish key replacement
// @namespace http://example.com/
// @version 0.1
// @description Type a backtick (`) after a letter to get the turkish variation.
// @author Simon Hobbs
// @match https://www.duolingo.com/skill/*
// @grant none
// ==/UserScript==
@simesy
simesy / EntityLookup.php
Last active March 27, 2018 03:07
Migrate process plugin: entity_lookup
<?php
/**
* @file
* Contains \Drupal\migrate_entity_lookup\Plugin\migrate\process\EntityLookup.
*/
namespace Drupal\migrate_entity_lookup\Plugin\migrate\process;
use Drupal\migrate\ProcessPluginBase;
# Simple colors and git status related functions.
COLOR_RED="\033[0;91m"
COLOR_YELLOW="\033[0;93m"
COLOR_GREEN="\033[0;32m"
COLOR_PURPLE="\033[0;95m"
COLOR_BLUE="\033[0;94m"
COLOR_WHITE="\033[0;37m"
COLOR_RESET="\033[0m"
[user]
email = [email protected]
name = Joe Bloggs
[push]
default = simple
[alias]
co = checkout
br = branch
ci = commit
st = status
(function ($) {
Drupal.behaviors.catchSomeDrupalAjaxAlerts = {
attach: function(context, settings) {
// Replace this simple core function with one that won't blurt empty messages.
Drupal.displayAjaxError = function (message) {
if (message && !Drupal.beforeUnloadCalled) {
alert(message);
2017/06/15 23:43:44 [INFO] Terraform version: 0.9.8 8d560482c34e865458fd884cb0790b4f73f09ad1
2017/06/15 23:43:44 [INFO] Go runtime version: go1.8
2017/06/15 23:43:44 [INFO] CLI args: []string{"/usr/local/bin/terraform", "apply", "-var-file", "tests/test.tfvar", "-var", "identifier=cheese", "-var", "remote_access=false"}
2017/06/15 23:43:44 [DEBUG] Detected home directory from env var: /Users/si
2017/06/15 23:43:44 [DEBUG] Detected home directory from env var: /Users/si
2017/06/15 23:43:44 [DEBUG] Attempting to open CLI config file: /Users/si/.terraformrc
2017/06/15 23:43:44 [DEBUG] File doesn't exist, but doesn't need to. Ignoring.
2017/06/15 23:43:44 [INFO] CLI command args: []string{"apply", "-var-file", "tests/test.tfvar", "-var", "identifier=cheese", "-var", "remote_access=false"}
2017/06/15 23:43:44 [DEBUG] Detected home directory from env var: /Users/si
2017/06/15 23:43:44 [DEBUG] command: loading backend config file: /Users/si/Dev/lilengine/tf_lemp/tf_lemp
@simesy
simesy / composer.json.js
Last active August 10, 2017 10:54
Initial composer.json from drupal-composer/drupal-project.
{
"name": "drupal-composer/drupal-project",
"description": "Project template for Drupal 8 projects with composer",
"type": "project",
"license": "GPL-2.0+",
"authors": [
{
"name": "Si",
"role": "Developer"
}