Skip to content

Instantly share code, notes, and snippets.

@skwashd
skwashd / .travis.yml
Created Jun 29, 2016
Incrementally improve your Drupal code
View .travis.yml
language: php
sudo: false
php:
- 5.6
install:
# Remove xdebug to make composer faster.
- phpenv config-rm xdebug.ini
View Ristretto-Affogato.kbd.json
[
{
"backcolor": "#000000",
"name": "Ristretto Affogato",
"author": "/u/instant_sunshine",
"switchMount": "cherry",
"switchBrand": "cherry",
"switchType": "MX1A-E1xx",
"plate": true
},
View gist:d5863d30d2ac492840d1
# hubot
description "Hubot Slack bot"
author "Adam Whittingham <emailaddress>"
start on filesystem or runlevel [2345]
stop on runlevel [!2345]
# Path to Hubot installation
env HUBOT_DIR='/opt/hubot/kaytoo/'
@robknight
robknight / gist:9601194
Created Mar 17, 2014
Drush via Composer in Puppet
View gist:9601194
composer::project {'drush':
project_name => 'drush/drush',
target_dir => '/opt/drush',
version => 'dev-master'
}
file {'/usr/bin/drush':
ensure => 'link',
target => '/opt/drush/drush'
}
@nodesocket
nodesocket / kibana
Created Jul 7, 2013
Kibana init.d service script.
View kibana
#!/bin/bash
### BEGIN INIT INFO
# Provides: kibana
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Make sense of a mountain of logs.
### END INIT INFO
@nodesocket
nodesocket / logstash
Created Jul 7, 2013
LogStash init.d service script.
View logstash
#! /bin/sh
#
# /etc/rc.d/init.d/logstash
#
# Starts Logstash as a daemon
#
# chkconfig: 2345 20 80
# description: Starts Logstash as a daemon
### BEGIN INIT INFO
View drupal2jekyll.rb
#
# Jekyll migrator for Drupal 7+
# adrianmejia.com
#
require 'rubygems'
require 'sequel'
require 'fileutils'
require 'yaml'
@malarkey
malarkey / Contract Killer 3.md
Last active Jul 31, 2021
The latest version of my ‘killer contract’ for web designers and developers
View Contract Killer 3.md

When times get tough and people get nasty, you’ll need more than a killer smile. You’ll need a killer contract.

Used by 1000s of designers and developers Clarify what’s expected on both sides Helps build great relationships between you and your clients Plain and simple, no legal jargon Customisable to suit your business Used on countless web projects since 2008

…………………………

@stewsnooze
stewsnooze / gist:1451329
Created Dec 9, 2011
Detecting errors in drush in Jenkins
View gist:1451329
YOURDRUSHCOMMAND 2>&1 |tee /tmp/test$BUILD_ID
if [ `grep -e "Fatal error" /tmp/test$BUILD_ID | wc -l` != 0 ]; then
ERROR_LEVEL=1
fi
.....
if [ `grep -e "^.* passes," /tmp/test$BUILD_ID | grep -v "0 fails" | wc -l` == 0 ]; then
echo "exited $ERROR_LEVEL" > /tmp/exit_code
exit $ERROR_LEVEL
else
exit 1