Skip to content

Instantly share code, notes, and snippets.

View paultreny's full-sized avatar

Paul Reny paultreny

View GitHub Profile
#!/bin/bash
target=$1
filename=`basename $1`
image="${TMPDIR}${filename}.png"
rsrc="${TMPDIR}icn.rsrc"
# Create a thumbnail from the file preview
qlmanage -t -s 512 -o ${TMPDIR} $target
javascript:(function(){var p=document.createElement("p");p.innerHTML="<strong>Loading&hellip;</strong>";p.id="loadingp";p.style.padding="20px";p.style.background="#fff";p.style.left="20px";p.style.top=0;p.style.position="fixed";p.style.zIndex="9999999";p.style.opacity=".85";document.body.appendChild(p);document.body.appendChild(document.createElement("script")).src="https://gist.github.com/ttscoff/6109434/raw/Bullseye.js?x="+(Math.random());})();
@paultreny
paultreny / dabblet.css
Created July 29, 2013 09:49 — forked from LeaVerou/dabblet.css
Loading animation like the one seen on http://www.freeger.com/projects/contextad/ with CSS
/**
* Loading animation like the one seen on http://www.freeger.com/projects/contextad/ with CSS
* Caveat: Not DRY. The content needs to be repeated in a data- attribute (or directly in the CSS).
*/
body {
background: #ccc51c;
min-height: 100%;
}
#!/bin/bash
if [ "$1" = "-h" -o "$1" = "--help" -o -z "$1" ]; then cat <<EOF
appify v3.0.1 for Mac OS X - http://mths.be/appify
Creates the simplest possible Mac app from a shell script.
Appify takes a shell script as its first argument:
`basename "$0"` my-script.sh

OS X Screencast to animated GIF

This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.

Screencapture GIF

Instructions

To capture the video (filesize: 19MB), using the free "QuickTime Player" application:

<?php
/**
* WordPress Query Comprehensive Reference
* Compiled by luetkemj - luetkemj.com
*
* CODEX: http://codex.wordpress.org/Class_Reference/WP_Query
* Source: http://core.trac.wordpress.org/browser/tags/3.5.1/wp-includes/query.php
*/
$args = array(
@paultreny
paultreny / dabblet.css
Created July 5, 2013 06:14 — forked from round/dabblet.css
Fixed ↔ Fluid Width Transitions
/* Fixed ↔ Fluid Width Transitions */
#outer {
display: block;
background: #fff;
width: 0;
overflow: visible;
padding: 1em;
margin: 0 auto; /*center on page*/
-webkit-transition: width 1s linear;
}
————————————————————————————————————————————————————————————————————————————————————————————————————
BBEDIT REGULAR EXPRESSION GUIDE MODIFIED 2013-03-27 : 13:08
————————————————————————————————————————————————————————————————————————————————————————————————————
NOTES:
The PCRE (Perl Compatible Regular Expressions) engine is what BBEdit uses.
Items I'm unsure of are marked '# PCRE?'. The list while fairly comprehensive is not complete.

Mac web developer apps

This gist's comment stream is a collection of webdev apps for OS X. Feel free to add links to apps you like, just make sure you add some context to what it does — either from the creator's website or your own thoughts.

— Erik