Skip to content

Instantly share code, notes, and snippets.

// Media Queries in Sass 3.2
//
// These mixins make media queries a breeze with Sass.
// The media queries from mobile up until desktop all
// trigger at different points along the way
//
// And important point to remember is that and width
// over the portrait width is considered to be part of the
// landscape width. This allows us to capture widths of devices
// that might not fit the dimensions exactly. This means the break
@ziogaschr
ziogaschr / easyiosapps
Last active August 29, 2015 14:13 — forked from fbeeper/easyiosapps
#!/bin/bash
#
# Using the information available in the new iOS8 simulator for each
# device/runtime (device.plist), this script creates a readable folder structure
# (no UDIDs, just simple device/runtime names). Inside that structure it creates
# soft links to your apps in development.
#
# You can run this script every time you install an app to your simulator, or
# you can simply call it to access this folder making sure it will always be
# updated :)
@ziogaschr
ziogaschr / animation-pseudo-code.markdown
Last active August 29, 2015 14:19
Animations Pseudo-code using keyframes

Animations Pseudo-code using keyframes

// the below will be the images that you send over
var hexagon_shape = svg()
var checkmark_icon = svg()

// the views that are on the screen
var consent_view
@ziogaschr
ziogaschr / js-load-multiple-3rd-party-widgets-async.js
Last active December 15, 2015 13:49 — forked from zenorocha/multiple-3rd-party-widgets.js
JS: Load Multiple 3rd party widgets async
(function() {
var script,
scripts = document.getElementsByTagName('script')[0];
function load(url) {
script = document.createElement('script');
script.async = true;
script.src = url;
scripts.parentNode.insertBefore(script, scripts);
{
"scope": "source.js -string -comment -constant",
"completions": [
{ "trigger": "customtrigger.allowBlank\tBoolean", "contents": "allowBlank: $1${2:,}" },
{ "trigger": "customtrigger.allowOnlyWhitespace\tBoolean", "contents": "allowOnlyWhitespace: $1${2:,}" },
{ "trigger": "customtrigger.blankText\tString", "contents": "blankText: '$1'${2:,}" },
{ "trigger": "customtrigger.checkChangeBuffer\tNumber", "contents": "checkChangeBuffer: $1${2:,}" },
{ "trigger": "customtrigger.checkChangeEvents\tString[]", "contents": "checkChangeEvents: ['$1']${2:,}" },
{ "trigger": "customtrigger.dirtyCls\tString", "contents": "dirtyCls: '$1'${2:,}" },
@ziogaschr
ziogaschr / LUA-cURL fetch file in memory
Last active December 19, 2015 00:09
LUA: luacurl, fetch a file in memory
require("luacurl")
local c = curl.new()
function GET(url)
-- c:setopt(curl.OPT_VERBOSE, true) -- run curl in verbose mode
c:setopt(curl.OPT_URL, url)
c:setopt(curl.OPT_HEADER, true)
c:setopt(curl.OPT_CONNECTTIMEOUT, 3)
@ziogaschr
ziogaschr / wp-remove-junk-from-wphead-section.php
Last active December 26, 2015 23:19 — forked from tsevdos/remove-junk-from-wphead-section.php
WP: Remove junk from wphead in WordPress
// remove junk from head
remove_action('wp_head', 'rsd_link');
remove_action('wp_head', 'wp_generator');
remove_action('wp_head', 'feed_links', 2);
remove_action('wp_head', 'index_rel_link');
remove_action('wp_head', 'wlwmanifest_link');
remove_action('wp_head', 'feed_links_extra', 3);
remove_action('wp_head', 'start_post_rel_link', 10, 0);
remove_action('wp_head', 'parent_post_rel_link', 10, 0);
remove_action('wp_head', 'adjacent_posts_rel_link', 10, 0);
@ziogaschr
ziogaschr / css-add-noise-filter.css
Created November 9, 2013 12:46
CSS: adds noise filter by using a base64 background image
.noise {
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAAyCAMAAAAp4XiDAAAAUVBMVEWFhYWDg4N3d3dtbW17e3t1dXWBgYGHh4d5eXlzc3OLi4ubm5uVlZWPj4+NjY19fX2JiYl/f39ra2uRkZGZmZlpaWmXl5dvb29xcXGTk5NnZ2c8TV1mAAAAG3RSTlNAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEAvEOwtAAAFVklEQVR4XpWWB67c2BUFb3g557T/hRo9/WUMZHlgr4Bg8Z4qQgQJlHI4A8SzFVrapvmTF9O7dmYRFZ60YiBhJRCgh1FYhiLAmdvX0CzTOpNE77ME0Zty/nWWzchDtiqrmQDeuv3powQ5ta2eN0FY0InkqDD73lT9c9lEzwUNqgFHs9VQce3TVClFCQrSTfOiYkVJQBmpbq2L6iZavPnAPcoU0dSw0SUTqz/GtrGuXfbyyBniKykOWQWGqwwMA7QiYAxi+IlPdqo+hYHnUt5ZPfnsHJyNiDtnpJyayNBkF6cWoYGAMY92U2hXHF/C1M8uP/ZtYdiuj26UdAdQQSXQErwSOMzt/XWRWAz5GuSBIkwG1H3FabJ2OsUOUhGC6tK4EMtJO0ttC6IBD3kM0ve0tJwMdSfjZo+EEISaeTr9P3wYrGjXqyC1krcKdhMpxEnt5JetoulscpyzhXN5FRpuPHvbeQaKxFAEB6EN+cYN6xD7RYGpXpNndMmZgM5Dcs3YSNFDHUo2LGfZuukSWyUYirJAdYbF3MfqEKmjM+I2EfhA94iG3L7uKrR+GdWD73ydlIB+6hgref1QTlmgmbM3/LeX5GI1Ux1RWpgxpLuZ2+I+IjzZ8wqE4nilvQdkUdfhzI5QDWy+kw5Wgg2pGpeEVeCCA7b85BO3F9DzxB3cdqvBzWcmzbyMiqhzuYqtHRVG2y4x+KOlnyqla8AoWWpuBoYRxzXrfKuILl6SfiW
#!/usr/bin/env bash
# file: ~/.virtualenvs/postmkvirtualenv
# This hook is run after a new virtualenv is activated.
# setup python interpretor and sitepackages
# for Sublime Text's SublimeCodeIntel plugin.
# codeintel looks in the root of any folder opened via `subl foldername`
# for foldername/.codeintel/config
# it also looks in ~/.codeintel/config
#!/bin/sh
# Disable BT on local machine and enable it on remote machine, so KB/Mouse reconnect to remote machine.
#ensure local bluetooth is off
/usr/local/bin/blueutil off
#enable imac bluetooth
ssh destiny@Chriss-iMac.local '/usr/local/bin/blueutil on'