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
""" | |
Re-bucket input histogram in linear or exponential buckets. | |
Input: | |
value\tcount | |
Output: | |
quantized_value\tcount | |
""" |
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 | |
# find all branches which have been squash merged into master | |
require 'pp' | |
# all branches | |
branches = %x{git branch | sed s/^..//}.split.map(&:chomp) | |
# sort by branch age; generate pretty time stamp while we're at it | |
branch_times = branches.map{|branch| |
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 --git i/pam.d/common-auth w/pam.d/common-auth | |
index dc84b87..ff34113 100644 | |
--- i/pam.d/common-auth | |
+++ w/pam.d/common-auth | |
@@ -14,7 +14,7 @@ | |
# pam-auth-update(8) for details. | |
# here are the per-package modules (the "Primary" block) | |
-auth [success=1 default=ignore] pam_unix.so nullok_secure | |
+auth [success=1 default=ignore] pam_unix.so nullok_secure nodelay |
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
# encoding: UTF-8 | |
require 'pathname' | |
namespace :deploy do | |
desc 'Deploy archive to TestFlight' | |
task :testflight do | |
# Only useful if we're re-signing the app with a different cert. | |
# SIGNING_IDENTITY = ENV['CODE_SIGN_IDENTITY'] | |
# PROVISIONING_PROFILE = Pathname.new(ENV['BUILT_PRODUCTS_DIR']) + ENV['CONTENTS_FOLDER_PATH'] + ENV['EMBEDDED_PROFILE_NAME'] | |
raise 'This task can only be run as part of Xcode Archive build' if !ENV['ARCHIVE_PATH'] |
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 | |
require 'resolv' | |
require 'optparse' | |
require 'ostruct' | |
require 'pp' | |
$opts = OpenStruct.new | |
parser = OptionParser.new do |parser| | |
parser.banner = <<-EOS | |
#$0: |
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
- (BOOL)shouldAutorotate | |
{ | |
return YES; | |
} | |
- (NSUInteger)supportedInterfaceOrientations | |
{ | |
return UIInterfaceOrientationMaskAllButUpsideDown; | |
} |
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
require 'formula' | |
class Macvim < Formula | |
homepage 'http://code.google.com/p/macvim/' | |
url 'https://github.com/b4winckler/macvim/tarball/snapshot-66' | |
version '7.3-66' | |
sha1 'd11696f7089688fa96a45fc57410c60f6ca5a394' | |
head 'https://github.com/b4winckler/macvim.git', :branch => 'master' |
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
trap 'echo -ne "\033]0;${BASH_COMMAND%% *}\007"' DEBUG | |
function show_name { | |
if [[ -n "$BASH_COMMAND" ]]; then | |
echo -en "\033]0;`basename ${PWD}`\007" | |
fi | |
} | |
export PROMPT_COMMAND=${PROMPT_COMMAND:+${PROMPT_COMMAND%%;*( )};}'history -a;show_name' |
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
function 95p { tail -n +$((` wc -l $1 | cut -d ' ' -f 2 `*95/100)) $1 | head -n 1 ; }; |
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
sed -e '$a\' * |
OlderNewer