Skip to content

Instantly share code, notes, and snippets.

View cymen's full-sized avatar

Cymen Vig cymen

  • Vig Consulting, LLC
  • Remote
View GitHub Profile
(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);throw new Error("Cannot find module '"+o+"'")}var f=n[o]={exports:{}};t[o][0].call(f.exports,function(e){var n=t[o][1][e];return s(n?n:e)},f,f.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
(function (global){
!function(e){if("object"==typeof exports)module.exports=e();else if("function"==typeof define&&define.amd)define(e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.iPanel=e()}}(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);throw new Error("Cannot find module '"+o+"'")}var f=n[o]={exports:{}};t[o][0].call(f.exports,function(e){var n=t[o][1][e];r
@cymen
cymen / gist:11300440
Created April 25, 2014 19:31
CORS: Getty Connect API and jQuery POST SearchForImages example
$.ajax({
url: 'https://connect.gettyimages.com/v2/search/SearchForImages',
type: 'POST',
crossDomain: true,
dataType: 'json',
contentType: 'application/json',
data: JSON.stringify({
RequestHeader: {
Token: '__YOUR_TOKEN_HERE__'
},
! function(n) {
! function(n) {
function t(n, t) {
return Object.prototype.hasOwnProperty.call(n, t)
}
function e(n) {
return "undefined" == typeof n
}
var r = {},
~/dev/teespring/rails-teespring cvig (cv/do-not-change-product-pricing-when-admin-revising)$ gm
GraphicsMagick 1.3.19 2013-12-31 Q8 http://www.GraphicsMagick.org/
Copyright (C) 2002-2013 GraphicsMagick Group.
Additional copyrights and licenses apply to this software.
See http://www.GraphicsMagick.org/www/Copyright.html for details.
Usage: gm command [options ...]
Where commands include:
batch - issue multiple commands in interactive or batch mode
benchmark - benchmark one of the other commands
0 info it worked if it ends with ok
1 verbose cli [ 'node', '/usr/local/bin/npm', 'publish' ]
2 info using npm@2.7.0
3 info using node@v0.10.33
4 verbose node symlink /usr/local/bin/node
5 verbose publish [ '.' ]
6 silly cache add args [ '.', null ]
7 verbose cache add spec .
8 silly cache add parsed spec { raw: '.',
8 silly cache add scope: null,
var prolog = {};
// Constructor for variables.
function Var() {
this.ref = this;
}
// Constructor for compound terms.
@cymen
cymen / gist:1282505
Created October 12, 2011 20:51 — forked from saikat/gist:1084146
Stripe sample checkout form
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<title>Stripe Sample Form</title>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js"></script>
<script type="text/javascript" src="https://ajax.aspnetcdn.com/ajax/jquery.validate/1.8.1/jquery.validate.min.js"></script>
<script type="text/javascript" src="https://js.stripe.com/v1/"></script>
<script type="text/javascript">
def first(string, length)
string[0..length-1]
end
def rest(string, index)
if string[index] == " "
index += 1
end
return string[index..-1]
end
presenterData: function () {
var attributes = _.clone(this.model.attributes);
var that = this;
attributes.display_name = function() {
// logic here to return name as combination of fields
}
return attributes;
}
...
Name: {{display_name}}
...