This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"log" | |
"net/http" | |
"github.com/bitly/go-simplejson" | |
"github.com/gorilla/mux" | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sudo apt-get install xserver-xorg xserver-xorg-core x11-apps x11-xserver-utils |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<project name="Composer Targets" default="build"> | |
<property name="builddir" value="${basedir}/build"/> | |
<property name="composer" value="${builddir}/composer.phar"/> | |
<target name="php-check"> | |
<condition property="php" value="php"> | |
<not> | |
<isset property="${php}"/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
watch -n 5 --differences mysqladmin processlist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"flag" | |
"log" | |
"net/http" | |
"os" | |
"github.com/gorilla/mux" | |
"github.com/stretchr/gomniauth" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env php | |
<?php | |
require_once __DIR__ . '/../vendor/autoload.php'; | |
try { | |
// Get the arguments passed through the command line. | |
$args = (!empty($_SERVER['argv'])) ? $_SERVER['argv'] : array(); | |
if (!isset($args[0])) { | |
$args[0] = $_SERVER['PHP_SELF']; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# curl -L https://bit.ly/vagrant-setup-ubuntu > vagrant-setup.sh | |
# sudo sh vagrant-setup.sh | |
set -e | |
# Add the vagrant user as a password-less sudoer. | |
TMPFILE=$(mktemp) | |
echo "vagrant ALL=(ALL) NOPASSWD: ALL" > $TMPFILE |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mysql -B -N dbname -e "SHOW TABLES LIKE 'cache%'" | xargs -I {} mysql dbname -e "TRUNCATE {}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [ -z "$1" ]; then | |
echo "Filename required." | |
exit 1 | |
fi | |
while read LINE; do | |
URL=$(echo "$LINE" | awk '{print $1'}) | |
FILENAME=$(echo "$LINE" | awk '{print $2'}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
xvfb-run --server-args="-screen 0, 1024x768x24" wkhtmltopdf -q -B 0 -T 0 -L 0 -R 0 http://google.com google.com.pdf | |
convert -density 300 google.com.pdf -append google.com.jpg |
NewerOlder