Skip to content

Instantly share code, notes, and snippets.

View CarterA's full-sized avatar

Carter Allen CarterA

View GitHub Profile
#!/bin/bash
# Written on 04/20/10 by Carter Allen
# Copyright Opt-6 Products, LLC, 2010
# 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:
require 'toto'
# Rack config
use Rack::Static, :urls => ['/css', '/js', '/images', '/favicon.ico'], :root => 'public'
use Rack::CommonLogger
#if ENV['RACK_ENV'] == 'development'
use Rack::ShowExceptions
#end

title: Shapps
author: Carter Allen
date: 07/04/2010

shapp |sh app|
noun
A colloquial conjugation of the words "shit" and "app", which refers to an application, most likely distributed via Apple Inc.'s App Store, that is poorly designed, implemented, or both. The man was quite frustrated due to the large number of shapps in the App Store.

<shamelessplug>

- (void)runMethodWithParameter:(TheParam *)paramName shouldRunImmediately:(BOOL)runImmediately {
==> Build Environment
CC: /usr/bin/cc
CXX: /usr/bin/c++
LD: /usr/bin/cc
CFLAGS: -O3 -march=core2 -msse4.1 -w -pipe
CXXFLAGS: -O3 -march=core2 -msse4.1 -w -pipe
CPPFLAGS: -I/usr/local/Cellar/gettext/0.17/include -I/usr/local/Cellar/gettext/0.17/include
LDFLAGS: -L/usr/local/Cellar/gettext/0.17/lib -L/usr/local/Cellar/gettext/0.17/lib
MAKEFLAGS: -j2
PATH: /usr/local/Cellar/gettext/0.17/bin:/usr/local/Cellar/gettext/0.17/bin:/depot_tools:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/texbin:/usr/X11/bin:/Users/carterallen/bin/
cz:~ carterallen$ brew install -v glib > ~/Desktop/iconv_log.txt
libtool: install: warning: remember to run `libtool --finish /private/tmp/homebrew-glib-2.22.4-3AhP/glib-2.22.4/iconv/lib'
readlink: illegal option -- f
usage: readlink [-n] [file ...]
configure: WARNING: *** FAM support will not be built (FAM library not found) ***
ghash.c: In function ‘g_hash_table_insert_internal’:
ghash.c:261: warning: ‘first_tombstone’ may be used uninitialized in this function
ghash.c:261: note: ‘first_tombstone’ was declared here
giochannel.c: In function ‘g_io_error_get_from_g_error’:
giochannel.c:186: warning: control reaches end of non-void function
cz:~ carterallen$ brew install node
==> Downloading http://ftp.gnu.org/pub/gnu/gnutls/gnutls-2.8.5.tar.bz2
File already downloaded and cached to /Users/carterallen/Library/Caches/Homebrew
==> ./configure --prefix=/usr/local/Cellar/gnutls/2.8.5 --disable-debug --disabl
==> make install
cat: ./.prev-version: No such file or directory
Making install in lib
Making install in gl
{ echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
cat ./alloca.in.h; \
cz:~ carterallen$ brew install graphicsmagick
==> Downloading http://downloads.sourceforge.net/project/graphicsmagick/graphicsmagick/1.3.12/Graphi
File already downloaded and cached to /Users/carterallen/Library/Caches/Homebrew
==> ./configure --prefix=/usr/local/Cellar/graphicsmagick/1.3.12 --disable-dependency-tracking --ena
==> make install
/bin/sh /private/tmp/homebrew-graphicsmagick-1.3.12-zFNE/GraphicsMagick-1.3.12/ltdl/config/install-sh -d . ltdl/
cp ./ltdl/argz_.h ltdl/argz.h-t
mv ltdl/argz.h-t ltdl/argz.h
make install-am
\
// Quicksort.
int pivot, beginning[MAX_LEVELS], end[MAX_LEVELS], i=0, left, right, swap;
beginning[0]=0; end[0]=ARRAY_LENGTH;
while (i>=0) {
left=beginning[i]; right=end[i]-1;
if (left < right) {
pivot=randoms.randomNumbers[left];
while (left < right) {
// Mergesort functions
void cz_merge(uint32_t *left, uint32_t *right, uint32_t *array, int length) {
for (int li = 0; li < (length / 2); li++) {
array[li] = left[li];
}
for (int ri = 0; ri < ((length - 1) / 2 + 1); ri++) {
array[(length / 2) + ri] = right[ri];
}