Skip to content

Instantly share code, notes, and snippets.

View juliocesar's full-sized avatar

Julio Cesar Ody juliocesar

View GitHub Profile
@juliocesar
juliocesar / breakpoint.sass
Created February 10, 2014 21:47
A breakpoints mixin I use, taken from some post by Chris Coyer that I can't remember right now.
// Screen size breakpoints
// =======================
//
// Example usage:
//
// .page-header
// +breakpoint(desktop)
// width: 50%
// +breakpoint(tablet)
// width: 80%
describe "Asynchronous specs", ->
funcRunInBackground = ->
value = 1
wrapFuncRunInBackground = (done) ->
# setup for simmulating the async operation, a function run in the background
setTimeout ->
funcRunInBackground()
done()
, 3000
@juliocesar
juliocesar / gist:11162250
Last active August 29, 2015 14:00
Macbook Pro (Retina, mid 2012)

15" Macbook Pro (Retina, mid 2012)

Yo!

I'm selling my Macbook Pro Retina (mid 2012). This machine has served me well in many battles. It has witnessed me unleash the fury of a thousand suns while building many Internets around the world.

The specs:

  • Display: 15" Retina display.
  • Processor: 4 cores 2.3GHz Intel Core i7.
@juliocesar
juliocesar / gist:9b728487ae4709f8f265
Created July 2, 2014 00:55
My ST2 configuration
{
"caret_style": "phase",
"color_scheme": "Packages/Theme - Tech49/Tech49.tmTheme",
"ensure_newline_at_eof_on_save": true,
"folder_exclude_patterns":
[
".git",
".sass-cache",
"node_modules",
"public/javascript",
@juliocesar
juliocesar / catalanifyme.js
Last active August 29, 2015 14:08
catalanifyme.js
// Catalanify-me dot jay ass
// =========================
//
// Replaces all copy in your website with that famous sentence from an Adam
// Sandler film, "I'm here for the beer and the britches" (or was it something
// else? I can't remember…) said in Catalanese.
//
// Instalation:
//
// At some point in the page, load this script and run:
@juliocesar
juliocesar / velocity-animate.jsx
Last active August 29, 2015 14:25
A component for doing child transitions using Velocity.js
// Velocity Animate
// ================
//
// Inspired by https://gist.github.com/tkafka/0d94c6ec94297bb67091.
//
// Extend so it supports:
//
// 1) A transition object in the same format as the ones in the library below,
// directly to the component. Example:
//
(function($) {
$.stuff = function(bitoftext) {
this.bitoftext = bitoftext;
}
$.extend($.stuff, {
report: function() { alert(this.bitoftext) }
})
# largely inspired by http://blog.macromates.com/2006/keychain-access-from-shell/
namespace :deploy do
desc "Generates database.yml from info store in Keychain"
task :generate_database_yml do
account = ENV['KEYCHAIN_ACC']
security_stdout = `security find-generic-password -ga #{account} 2>&1 > /dev/null`
if security_stdout[/could not be found/]
rollback
var table = $('<table />').attr('id', 'host-' + host.host).
.append('<thead />')
.find('thead')
.append('<tr />')
.find('tr')
.append('<th class="name">File name</th>')
.append('<th class="size">Size</th>')
.parent()
.parent()
.append('<tfoot />')
@juliocesar
juliocesar / gist:57892
Created February 4, 2009 02:41 — forked from lachie/gist:57891
hmm
var table = $([
'<table>',
'<thead>,
'<tr'>,
'<th>Foo</th>',
'<th>Bar</th>',
'</tr>',
'</thead>',
'<tfoot />',
'<tbody />'