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
-- Adapted from these sources: | |
-- http://peterdowns.com/posts/open-iterm-finder-service.html | |
-- https://gist.github.com/cowboy/905546 | |
-- | |
-- Modified to work with files as well, cd-ing to their container folder | |
on run {input, parameters} | |
tell application "Finder" | |
set my_file to first item of input | |
set filetype to (kind of (info for my_file)) | |
-- Treats OS X applications as files. To treat them as folders, integrate this SO answer: |
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 ksh # solarized "iterm-24bit" proof-of-concept script. | |
#!/usr/bin/env sh # If you don't have ksh. But beware: bash nearly dies on this. | |
command echo "WARNING: This script requires 24bit color and GOOD UTF-8 support." | |
command echo "If in doubt, ctl-C NOW. Did your terminal die? You were warned!" | |
echo; for i in $(seq 5 1); do command echo $i...; sleep 1; done | |
# The Values | |
# ---------- |
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 sh # "brew which" -- derefernce paths for homebrew symlinks. | |
# "brew exec" -- exec these instead of printing/returning. | |
# G. Nixon 2014. Public domain or license of your choice; no warranty, etc. | |
iam=$(echo "$(basename "$0")" | cut -c6-10); cellar="$(brew --prefix)" | |
bin=$cellar/bin | |
optbin=$cellar/opt/bin |
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
index: a/acinclude.m4 b/acinclude.m4 | |
--- a/acinclude.m4 | |
+++ b/acinclude.m4 | |
@@ -3273,0 +3274,38 @@ | |
+ | |
+ | |
+# Test generated assembly for markers of unusual "objects" that cause test to fail. | |
+ | |
+# Compilers sometimes generate "strange objects" - things that are not machine code, | |
+# but instead, some type of intermediately processed data (i.e., LTO/IPO/WPA/IR). |
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 sh # "somebodyrandom" -- random but REAL names and addresses. # | |
#=- G. Nixon, 2014; Public domain or license of your choice. DO NOT ABUSE. -=# | |
#==------------------------------------------------------------------------==# | |
# # | |
# Randomly generate (from census data and white pages) a valid name, address # | |
# and phone number. THIS IS NOT stealing anyone's identity, as it is public # | |
# information. It is not meant for harassing/spamming people, but for online # | |
# registration forms where this type infomation is required (and validated), # | |
# and one wishes to remain anonymous, along with a throw-away email address. # | |
# # |
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 node #// -*- Mode: Node.js JavaScript; tab-width: 4; -*- | |
/* | |
--- | |
url: http://gist.github.com/441101 | |
name : safari-get-html | |
description : safari-get-html will rock your socks! | |
authors : Thomas Aylott | |
copyright : © 2010 Thomas Aylott | |
license : MIT |
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
:; I="$(basename $0)"; [ -z $BROWSER ] && open=open || open="$BROWSER" | |
[ $# -eq 0 ] && set -- -; [ "$1" = "-" ] && [ -t 0 ] && | |
echo "Usage: [ COMMAND | $I ] | [ $I < FILE ] | [ $I FILE ... ]" >&2 && exit | |
for what; do where="/tmp/$(od -N2 < /dev/urandom | openssl dgst -sha1).html" | |
cat "$what" > "$where" && $open "$where"; sleep 1 && rm -f "$where" & done | |
## Or, you might prefer what I use: | |
# cat "$what" > "$where" && qlmanage -p "$where" >/dev/null 2>&1; sleep 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
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
OlderNewer