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
module Enumerable | |
def deep_freeze | |
unless self.is_a? String | |
frozen = self.dup.each do |key, value| | |
if (value.is_a?(Enumerable) && !value.is_a?(String)) | |
value.deep_freeze | |
else | |
value.freeze | |
end | |
end |
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 -xe | |
EBS_DEVICE='/dev/sdh' | |
INSTANCE_ID=$1 | |
AKI=${2:-'aki-5f15f636'} | |
ARI=${3:-'ari-0915f660'} | |
ARCH=${4:-'i386'} | |
SIZE=${5:-10} | |
AZ=${6:-'us-east-1d'} | |
NAME=${7:-"ami-from-$INSTANCE_ID"} |
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 ruby | |
#/ Usage: <progname> [options]... | |
#/ How does this script make my life easier? | |
# ** Tip: use #/ lines to define the --help usage message. | |
$stderr.sync = true | |
require 'optparse' | |
# default options | |
flag = false | |
option = "default value" |
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 bash | |
# ---------------------------------------------------- | |
# | |
# Automated setup for a Ubuntu server with git, ruby, rvm, nginx. | |
# (Used at Carbonmade) | |
# | |
# Usage: | |
# - SCP this file to your server: scp ubuntu_setup.sh you@server:~ | |
# - Make it executable: chmod +x ubuntu_setup.sh | |
# - Run it: bash ubuntu_setup.sh |
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
Copyright (C) 2011 by Colin MacKenzie IV | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights | |
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
copies of the Software, and to permit persons to whom the Software is | |
furnished to do so, subject to the following conditions: | |
The above copyright notice and this permission notice shall be included in |
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 ruby | |
# A simply utility to show character counts for each line of input and | |
# highlight lines longer than 80 characters. | |
# | |
# Written as an example for http://jstorimer.com/2011/12/12/writing-ruby-scripts-that-respect-pipelines.html | |
# | |
# Examples: | |
# | |
# $ hilong Gemfile |
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 bash | |
# Compress MySQL tables on disk. | |
# Author: Andrew Berry, andrew.berry@lullabot.com | |
# | |
# Compress all tables in a MySQL InnoDB database using compression from the | |
# Barracuda table format. Tables have to already be in the Barracuda file | |
# format to actually compress tables, otherwise the table setting is ignored. | |
# | |
# innodb_file_per_table = 1 MUST be set in my.cnf for compression to work. |
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
diff -r 19cc3b567644 make/sun/font/Makefile | |
--- a/make/sun/font/Makefile Wed Jan 22 12:34:24 2014 -0800 | |
+++ b/make/sun/font/Makefile Fri Jan 24 21:41:23 2014 +0900 | |
@@ -138,7 +138,7 @@ | |
ifeq ($(USING_SYSTEM_FT_LIB), false) | |
FREETYPE_LIB = $(LIB_LOCATION)/$(LIB_PREFIX)freetype.$(LIBRARY_SUFFIX).6 | |
endif | |
- OTHER_LDLIBS += -L$(FREETYPE_LIB_PATH) -lfreetype | |
+ OTHER_LDLIBS += -L$(FREETYPE_LIB_PATH) -lfreetype -lfontconfig | |
endif |
OlderNewer