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 awk -f | |
BEGIN { | |
shiftWidth = 4 | |
expandedTab = createExpandedTab(4) | |
} | |
{ | |
s = stripTrailingWhitespace($0) | |
s = expandTabs(s, expandedTab) |
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 awk -f | |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
# Copyright © 2011, Damian Carrillo | |
# All rights reserved. | |
# | |
# Redistribution and use in source and binary forms, with or without | |
# modification, are permitted provided that the following conditions are met: | |
# | |
# * Redistributions of source code must retain the above copyright notice, this | |
# list of conditions and the following disclaimer. |
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 | |
for i in $(seq 1 5); do if [ $i = "1" ]; then echo -n $i; sleep 1; else echo -n "^H$i"; sleep 1; fi; done |
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 | |
# | |
# Launches the development AppServer | |
# | |
# Usage: | |
# ./debug.sh --port=8888 ~/Development/Project/target/Project-SNAPSHOT | |
[ -z "${DEBUG}" ] || set -x # trace if $DEBUG env. var. is non-zero | |
SDK_BIN=`dirname $0 | sed -e "s#^\\([^/]\\)#${PWD}/\\1#"` # sed makes absolute | |
SDK_LIB=$SDK_BIN/../lib |
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/sbin/dtrace -Zs/* | |
sqlite-snoop.d | |
Author: Damian Carrillo | |
Usage: sudo ./libsqlite_snoop.d <pid> | |
Date: 2012-04-03 | |
*/ |
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 | |
# This script builds the iOS and Mac openSSL libraries | |
# Download openssl http://www.openssl.org/source/ and place the tarball next to this script | |
# Credits: | |
# https://github.com/st3fan/ios-openssl | |
# https://github.com/x2on/OpenSSL-for-iPhone/blob/master/build-libssl.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
enum Color { case R, B } | |
indirect enum Tree<Element: Comparable> { | |
case Empty | |
case Node(Color,Tree<Element>,Element,Tree<Element>) | |
init() { self = .Empty } | |
init(_ x: Element, color: Color = .B, | |
left: Tree<Element> = .Empty, right: Tree<Element> = .Empty) |
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
import Cocoa | |
class WindowController: NSWindowController { | |
} | |
class AppDelegate: NSObject { | |
var mainWindow: NSWindow? | |
var mainController: NSWindowController? | |
} |
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
### Keybase proof | |
I hereby claim: | |
* I am damiancarrillo on github. | |
* I am damiancarrillo (https://keybase.io/damiancarrillo) on keybase. | |
* I have a public key ASCw9PJB648jvofkgm68SJelkyulpuRJ2D5hVq84Zdz_pAo | |
To claim this, I am signing this object: |
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 | |
for i in *.HEIC | |
do | |
#echo $i | |
#ffmpeg -i "$i" -frames:v 1 -vsync vfr -q:v 1 -an "${i%HEIC}jpg" | |
sips --setProperty format jpeg "$i" --out "${i%HEIC}jpg" | |
done |
OlderNewer