Skip to content

Instantly share code, notes, and snippets.

View joelkallman's full-sized avatar

Joel Kallman joelkallman

View GitHub Profile
@ArturDorochowicz
ArturDorochowicz / certificates.md
Last active March 31, 2020 19:33
Creating SSL certificates with OpenSSL and other notes on creating certificates.
var Cartridge = require('../models/cartridge');
var CartridgeRoute = Ember.Route.extend({
model: function(params) {
// `fetch` returns a promise when `find` does not
return Cartridge.fetch(params.uid).then(function(record) {
Ember.run.next(record, function() {
record.deserialize();
});
return record;
@sebastianseilund
sebastianseilund / merged_array.js
Last active December 20, 2015 07:58
An implementation of a merged array in Ember.js that combines items from multiple source arrays so you can easily list them together in your Handlebars templates. Read the blog post at the [Billy's Billing Developer Blog](http://dev.billysbilling.com/blog/How-to-merge-multiple-data-sources-into-one-array-in-Ember-js)
/**
* `Ember.MergedArray` is an array that observes multiple other arrays (called source arrays) for changes and includes
* all items from all source arrays in an efficient way.
*
* Usage:
*
* ```javascript
* var obj = Ember.Object.create({
* people: [
* {
@lukemelia
lukemelia / buffered_proxy.js
Last active May 5, 2016 20:47
Buffered Proxy, extracted from Yapp codebase
var empty, get, set,
__hasProp = {}.hasOwnProperty;
get = Ember.get;
set = Ember.set;
empty = function(obj) {
var key;
for (key in obj) {
if (!__hasProp.call(obj, key)) continue;
@JimWestergren
JimWestergren / index-with-redis.php
Last active February 11, 2023 18:28
Redis as a Frontend Cache for WordPress
<?php
/*
Author: Jim Westergren & Jeedo Aquino
File: index-with-redis.php
Updated: 2012-10-25
This is a redis caching system for wordpress.
see more here: www.jimwestergren.com/wordpress-with-redis-as-a-frontend-cache/
@tanakahisateru
tanakahisateru / scp-git-diff.sh
Created November 17, 2011 09:56
Send changed files under Git via SCP (if SSH password auth)
#!/bin/sh
if [ $# -ne 1 ]; then
echo "$0 <git-commit>" 1>&2
exit 1
fi
git diff --name-status $1
read -p "Press any key to execute..."