Skip to content

Instantly share code, notes, and snippets.

anonymous
anonymous / Pharma-package-in-CSS.markdown
Created December 15, 2014 11:26
Pharma package in CSS

Pharma package in CSS

Attempt at a realistic pharmaceutical box that will work in ie10. I've got a project that uses an element like this, but that one requires preserve-3d, which is not available in ie10.

For anyone wondering about the details on the box, they're all contrived and follow Australian style guides as specified by client.

I started with a cube forked from dehash's Pen ie10 css 3d cube - cross browser and went from there.

fork of http://www.cssplay.co.uk/menu/cssplay-3d-cube-animation-for-ie10.html - CSS play - 3D Animated Cube for Internet Explorer IE10, Firefox, Safari and Chrome

#!/bin/bash
# Atom on Ubuntu
# Tested on Ubuntu 14.04 LTS
# Add repository for Atom
sudo add-apt-repository ppa:webupd8team/atom -y
# Install Atom and Git
sudo apt-get update
@atommclain
atommclain / ZigBee_Lights.md
Last active February 12, 2017 21:58
An informal list of ZigBee lights

##Philips

###Hue http://www2.meethue.com/en-us/the-range/hue/

Name Capabilities Cost lumen output
A19 Connected Bulb Color

Tunable White

$59.95 600 @ 4000K
510 @ 3000K
360 @ 2000K
550 @ 6500K
BR30 Connected Bulb Color

Tunable White

$59.95 630 @ 4000K
538 @ 3000K
376 @ 2000K
581 @ 6500K
GU10 Connected Bulb ColorTunable White $59.95 300 @ 4000K 210 @ 3000K 145 @ 2000K 230 @ 6500K
@rimusz
rimusz / preemtible_kubernetes.md
Last active July 7, 2018 02:52 — forked from tsuri/preemtible_kubernetes.md
kubernetes cluster w/ pre-emptible instances

Kubernetes clusters using preemtible instances

Motivation

People experimenting with kubernetes clusters on the GKE not necessarily have money to keep a full cluster on at all time. GKE clusters can be easily resized, but this still incurs in the full instance cost when the cluster is up.

Google has added preemptible instances that are ideal for many

@rupl
rupl / sw-font-load.js
Created December 7, 2015 11:54
Use Service Worker to load fonts async/direct via client-side logic.
// Load fonts async by default
// Load sync from SW cache when available.
//
// Snippet assumes your Service Worker caches fonts as part of installation, so that
// an 'activated' Service Worker means the fonts are cached with 100% confidence.
if (
'serviceWorker' in navigator &&
navigator.serviceWorker.controller !== null &&
navigator.serviceWorker.controller.state === 'activated'
) {
@JosefJezek
JosefJezek / atom-on-ubuntu.sh
Last active January 5, 2019 18:06
[Atom on Ubuntu] #Ubuntu
#!/bin/bash
# Atom on Ubuntu
# Tested on Ubuntu 14.04 LTS
# Add repository for Atom
sudo add-apt-repository ppa:webupd8team/atom -y
# Install Atom and Git
sudo apt-get update
@simora
simora / setup-sync-node.sh
Last active October 16, 2019 21:09
Script to setup the Hardkernel Odroid HC1/2 and XU4 for Wireguard and Resilio-sync
#!/bin/bash
function set_hostname() {
read -r -p 'Hostname: ' hostname
hostname $hostname
}
function install_pkgs() {
apt install -y vim libmnl-dev libelf-dev build-essential pkg-config git parted xfsprogs
apt-mark hold linux-odroid-5422
@simenbrekken
simenbrekken / uploader.js
Created May 2, 2012 13:38
Fetch, resize via ImageMagick and store image on Amazon S3 with node.js
var spawn = require('child_process').spawn,
aws2js = require('aws2js'),
http = require('http'),
urlutil = require('url')
mime = require('mime'),
Buffers = require('buffers');
var settings = {
s3: {
key: 'key',
@randallmlough
randallmlough / hugo-img-srcset.html
Last active May 8, 2021 12:31
A hugo img srcset partial that auto resizes images
<style>
img {
max-width: 100%;
}
</style>
<h1>Creating a srcset loop based on Resources</h1>
<!--
NOTE: This requires Hugo 0.32
@UndefinedOffset
UndefinedOffset / nr-deploy-post-merge-hook.sh
Last active July 9, 2021 10:19
A simple git deploy hook for notifying New Relic of deployments, it assumes that the base folder name of the repository is the application name. To set git to use this script you simply add this file into your .git/hooks folder as "post-merge".
#!/bin/bash
#New Relic API Key see https://docs.newrelic.com/docs/apis/rest-api-v2/requirements/api-key#creating
NR_API_KEY="INSERT_API_KEY_HERE"
#Find New Relic App Name, if your top level folder is not the name of your application change the below two lines to simply NR_APP_NAME="MY_APP_NAME".
NR_APP_NAME=$(git rev-parse --show-toplevel)
NR_APP_NAME=$(basename "$NR_APP_NAME")
#Get the current git branch