Skip to content

Instantly share code, notes, and snippets.

@miguelbermudez
miguelbermudez / gist:1244106
Created September 27, 2011 01:53 — forked from atduskgreg/gist:1244103
file_locator.rb
puts "Called from: #{File.expand_path(File.dirname("."))}"
puts __FILE__
puts "last: " + File.dirname(__FILE__).split("/").last
puts pwd = File.expand_path(File.dirname(__FILE__))
puts "parent dir:"
ar = pwd.split("/")
puts "/#{ar[ar.length-2]}"
@miguelbermudez
miguelbermudez / style.sass
Created November 4, 2011 06:05 — forked from destroytoday/style.sass
Prevents iOS from changing the font size of paragraphs in landscape
@media only screen and (min-device-width: 320px) and (max-device-width: 1024px)
html
-webkit-text-size-adjust: none
@miguelbermudez
miguelbermudez / svg-path-to-json.py
Created September 28, 2012 18:30 — forked from robflaherty/svg-path-to-json.py
Extract SVG paths and convert to JSON for use with Raphael.js
from xml.dom import minidom
import json
config = {
'svg_file' : 'map.svg',
'js_file' : 'map.js',
'js_var' : 'svgMap'
}
svg = minidom.parse(config['svg_file'])
@miguelbermudez
miguelbermudez / gist:3805422
Created September 29, 2012 23:34 — forked from saetia/gist:1623487
Clean Install – Mountain Lion OS X 10.8
@miguelbermudez
miguelbermudez / gist:4037203
Last active October 12, 2015 13:58 — forked from saetia/gist:1623487
Clean Install – Mountain Lion OS X 10.8
@miguelbermudez
miguelbermudez / Custom.css
Created November 11, 2012 23:12 — forked from wafflesnatcha/Custom.css
Custom.css - WebKit Inspector styles for Google Chrome
/**
* Custom.css
* WebKit Inspector styles for Google Chrome
*
* by Scott Buchanan <[email protected]>
* http://wafflesnatcha.github.com
*
* Fugue Icons by Yusuke Kamiyamane
* http://p.yusukekamiyamane.com
*/
@miguelbermudez
miguelbermudez / Blur.cpp
Created December 5, 2012 05:02 — forked from roxlu/Blur.cpp
Blur shader 2 passing, ping pong attachments
#include <Blur.h>
#define ASSERT_BLUR_SETUP() { \
if(!is_setup) { \
printf("ERROR: not setup.\n"); \
return; \
} \
}
Blur::Blur()
#!/bin/bash
# log into your server
ssh root@[server ipaddress]
# change root password
passwd
# update all packages and operating system
apt-get update && apt-get --yes upgrade
#!/bin/bash
# This little script creates incremental rsync backups from my
# external Lightroom Library (but could be anything) to another
# external harddrive. Backups are important, you know.
# The result looks like this:
#
# 20120105-1759
# 20120107-1928