Skip to content

Instantly share code, notes, and snippets.

received_request_conditions = {
update_type: {
source: 'update_type',
operator: 'is',
value: ['Create']
},
status_id: {
source: 'status_id',
operator: 'is_not',
value: ['3']
IE 11 install:
==============
$ curl -s https://raw.githubusercontent.com/xdissent/ievms/master/ievms.sh | env IEVMS_VERSIONS="11" bash
Error:
=====
Do you agree to these license terms and conditions (y/n)? y
Installation of "Oracle VM VirtualBox Extension Pack" aborted.
\nERROR: Failed to install Oracle VM VirtualBox Extension Pack from /Users/$user/.ievms/Oracle_VM_VirtualBox_Extension_Pack-5.1.30.vbox-extpack, error code (1)\n
$sidebar-border: solid 1px $zd-color-platinum;
$sidebar-width: 350px;
.c-sidebar {
border: $sidebar-border;
background-color: $zd-color-white;
height: 100%;
right: 0;
top: 0;
width: $sidebar-width;
# The PUT request takes one parameter, a `macros` object that lists the macros to update.
#
# Each macro must have an id and any of the following parameters:
#
# | Name | Description |
# | -------- | ----------------------------------- |
# | id | The ID of the macro to update. |
# | active | The new active status of the macro. |
# | position | The new position of the macro. |
@kgarfinkel
kgarfinkel / gist:4fdafc33e45d3ec15cf1
Created November 11, 2014 19:16
Transferring Org Courses to a Personal Accout
// Fetch org course
$course_api me orgs/121444745/courses | jq '.[] | {"id": .id, "programId": .programId}'
{
"id": "qnmizo",
"programId": "121444745"
}
// Create new programId
$ course_api me programs post {}
{
define [
'cdn.jquery'
'cdn.backbone'
'scripts/helpers/common'
'scripts/mediator'
'site/models/notification'
'site/collections/notifications'
'site/views/notification_collection'
], ($, Backbone, commonHelper, mediator, Notification, Notifications, NotificationCollectionView) ->
describe.only('when user is verified and all fields are valid', function () {
var apiUserSession = {
sessionId: 'full-sail',
user: apiUsers[users.user.api_id]
};
given.apiUserCanBeSignedInWith(apiUserSession);
given.anExistingApiUserWith(apiUsers[users.user.api_id]);
// Sign a user in
signin: function (user, callback) {
var self = this,
attributes = { 'sessionId': 'foobar' };
if (typeof(user) == 'function') {
callback = user;
}
@kgarfinkel
kgarfinkel / gist:7064111
Last active December 26, 2015 00:29
Javascript's 'bind' re-implemented.
var bind = function(fn, context) {
var args = Array.prototype.slice.call(arguments, 2);
return function() {
return fn.apply(context, args.concat(Array.prototype.slice.call(arguments)));
};
};
@kgarfinkel
kgarfinkel / gist:7064078
Created October 20, 2013 02:16
Javascript's 'apply' re-implemented.
var apply = function(fn, context) {
var args = Array.prototype.slice.call(arguments, 2),
result;
context.fn = fn;
result = context.fn(args);
delete this.fn;
return result;
};